diff --git a/src/stream-tcp-private.h b/src/stream-tcp-private.h index f1a462c06d..4232999cd5 100644 --- a/src/stream-tcp-private.h +++ b/src/stream-tcp-private.h @@ -73,11 +73,11 @@ enum /* Macro's for comparing Sequence numbers * Page 810 from TCP/IP Illustrated, Volume 2. */ -#define SEQ_EQ(a,b) ((int)((a) - (b)) == 0) -#define SEQ_LT(a,b) ((int)((a) - (b)) < 0) -#define SEQ_LEQ(a,b) ((int)((a) - (b)) <= 0) -#define SEQ_GT(a,b) ((int)((a) - (b)) > 0) -#define SEQ_GEQ(a,b) ((int)((a) - (b)) >= 0) +#define SEQ_EQ(a,b) ((int32_t)((a) - (b)) == 0) +#define SEQ_LT(a,b) ((int32_t)((a) - (b)) < 0) +#define SEQ_LEQ(a,b) ((int32_t)((a) - (b)) <= 0) +#define SEQ_GT(a,b) ((int32_t)((a) - (b)) > 0) +#define SEQ_GEQ(a,b) ((int32_t)((a) - (b)) >= 0) typedef struct TcpSession_ { uint8_t state; diff --git a/src/stream-tcp.c b/src/stream-tcp.c index 511995b53b..68acac9302 100644 --- a/src/stream-tcp.c +++ b/src/stream-tcp.c @@ -76,7 +76,7 @@ static Pool *ssn_pool = NULL; static SCMutex ssn_pool_mutex; #ifdef DEBUG -static uint64_t ssn_pool_cnt; +static uint64_t ssn_pool_cnt = 0; static SCMutex ssn_pool_cnt_mutex; #endif