From 2ec7740c3a4661c2b0c05278a6f756c291547647 Mon Sep 17 00:00:00 2001 From: Ichito Nagata Date: Wed, 22 Mar 2017 17:03:52 +0900 Subject: suppress gcc complaint --- hiredis.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hiredis.h b/hiredis.h index 423d5e5..77d5797 100644 --- a/hiredis.h +++ b/hiredis.h @@ -99,7 +99,7 @@ * need to copy the result into our private buffer. */ \ if (err_str != (buf)) { \ strncpy((buf), err_str, ((len) - 1)); \ - buf[(len)-1] = '\0'; \ + (buf)[(len)-1] = '\0'; \ } \ } while (0) #endif -- cgit v1.2.3