summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGowtham Tammana2019-02-06 15:01:24 -0600
committerGowtham Tammana2019-02-18 16:21:16 -0600
commit9b59e596b4adefabbb686ce8845edef8114558fd (patch)
treed08b5d48396813493a1223e8d5d1d7e8a2ffb982
parenta36799d9329efcfff19e30e690156d5ebf7e0c55 (diff)
downloadti-gc320-driver-ti-5.0.11.p7-k4.19.tar.gz
ti-gc320-driver-ti-5.0.11.p7-k4.19.tar.xz
ti-gc320-driver-ti-5.0.11.p7-k4.19.zip
Fix -Werror=stringop-overflow= errors with gcc8ti-5.0.11.p7-k4.19
The following error is seen with gcc8 compiler ``` gc_hal_kernel_debug.h:131:5: error: ‘strncat’ specified bound 768 equal s destination size [-Werror=stringop-overflow=] ``` GCC8 appears to be strict with strncat length argument to ensure space is present for null character in destination string. Fixing the offending call to use correct length. Signed-off-by: Gowtham Tammana <g-tammana@ti.com>
-rwxr-xr-xsrc/hal/kernel/gc_hal_kernel_debug.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/hal/kernel/gc_hal_kernel_debug.c b/src/hal/kernel/gc_hal_kernel_debug.c
index 7bd0c57..ae55b8b 100755
--- a/src/hal/kernel/gc_hal_kernel_debug.c
+++ b/src/hal/kernel/gc_hal_kernel_debug.c
@@ -786,7 +786,7 @@ _PrintBuffer(
786 if (command) 786 if (command)
787 { 787 {
788 buffer[indent] = '\0'; 788 buffer[indent] = '\0';
789 gcmkSTRCAT(buffer, gcmSIZEOF(buffer), "] -- command\n"); 789 gcmkSTRCAT(buffer, gcmSIZEOF("] -- command\n"), "] -- command\n");
790 gcmkOUTPUT_STRING(buffer); 790 gcmkOUTPUT_STRING(buffer);
791 } 791 }
792} 792}