From fba06b5c791a9635eecf5ad6870959522829f243 Mon Sep 17 00:00:00 2001 From: William Robinet Date: Tue, 19 Jan 2021 17:25:02 +0100 Subject: [PATCH] Output error to stderr --- base/tcppack.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/base/tcppack.c b/base/tcppack.c index 330d366..f44777f 100644 --- a/base/tcppack.c +++ b/base/tcppack.c @@ -241,8 +241,7 @@ static int process_data_segment(conn,handler,p,stream,direction) l=p->len - p->tcp->th_off * 4; if(l < 0) { - if(!(NET_print_flags & NET_PRINT_JSON)) - printf("Malformed packet, computed TCP segment size is negative, skipping ...\n"); + fprintf(stderr,"Malformed packet, computed TCP segment size is negative, skipping ...\n"); return(0); }