From e9ebeafe79d35f88735a3f4124e694478782db3a Mon Sep 17 00:00:00 2001 From: Egor Date: Tue, 29 Aug 2023 22:08:59 +0300 Subject: [PATCH] detect: fix warning --- thtk/detect.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/thtk/detect.c b/thtk/detect.c index 1d07e2c..3bc715d 100644 --- a/thtk/detect.c +++ b/thtk/detect.c @@ -563,7 +563,7 @@ thdat_detect_iter( uint32_t v = out[i]; int j=0; for(;!(v&1);v>>=1, j++); - out[i] &= -1u << (j+1); + out[i] &= ~0u << (j+1); int entry_num = i*32 + j; if(entry_num >= DETECT_ENTRIES) { /* non-existent entry */ out[0]=out[1]=out[2]=out[3] = 0;