From 94505bbcf473b8bdd31566eea3c4b92a5350d3a4 Mon Sep 17 00:00:00 2001 From: Yuxuan Shui Date: Sat, 2 Feb 2019 02:12:01 +0000 Subject: [PATCH] Fix compiling on older gcc Signed-off-by: Yuxuan Shui --- src/string_utils.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/string_utils.c b/src/string_utils.c index 26b1c5bc..a19235f2 100644 --- a/src/string_utils.c +++ b/src/string_utils.c @@ -13,6 +13,7 @@ // strncpy(str, src1, len1) intentional truncates the null byte from src1. // strncpy(str+len1, src2, len2) uses bound depends on the source argument, // but str is allocated with len1+len2+1, so this strncpy can't overflow +#pragma GCC diagnostic ignored "-Wpragmas" #pragma GCC diagnostic ignored "-Wstringop-truncation" #pragma GCC diagnostic ignored "-Wstringop-overflow"