summaryrefslogtreecommitdiff
path: root/deps
diff options
context:
space:
mode:
authorYoongHM <yoonghm@users.noreply.github.com>2020-09-21 22:04:34 +0800
committerGitHub <noreply@github.com>2020-09-21 17:04:34 +0300
commit9216b96b4117009c75214bcc8aca048d472d2d14 (patch)
treed95c53cc656724e2f9c3ea7741ec7c25979051e4 /deps
parentd3faed875d4d50dca28be814e8898b4f8674922b (diff)
downloadredis-9216b96b4117009c75214bcc8aca048d472d2d14.tar.gz
Fix compilation warning in jemalloc's malloc_vsnprintf (#7789)
Change `val` to `unsigned char` before being tested. The fix is identical to the one that's been made in upstream jemalloc. warning is: src/malloc_io.c: In function ‘malloc_vsnprintf’: src/malloc_io.c:369:2: warning: case label value exceeds maximum value for type 369 | case '?' | 0x80: \ | ^~~~ src/malloc_io.c:581:5: note: in expansion of macro ‘GET_ARG_NUMERIC’ 581 | GET_ARG_NUMERIC(val, 'p'); | ^~~~~~~~~~~~~~~
Diffstat (limited to 'deps')
-rw-r--r--deps/jemalloc/src/malloc_io.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/deps/jemalloc/src/malloc_io.c b/deps/jemalloc/src/malloc_io.c
index 7bdc13f95..dd8826511 100644
--- a/deps/jemalloc/src/malloc_io.c
+++ b/deps/jemalloc/src/malloc_io.c
@@ -362,7 +362,7 @@ malloc_vsnprintf(char *str, size_t size, const char *format, va_list ap) {
} \
} while (0)
#define GET_ARG_NUMERIC(val, len) do { \
- switch (len) { \
+ switch ((unsigned char)len) { \
case '?': \
val = va_arg(ap, int); \
break; \