From 9ca8ba43fa045cc60e3999909357cca3b090332d Mon Sep 17 00:00:00 2001 From: Frank Dana Date: Sun, 24 Apr 2022 21:57:48 -0400 Subject: [PATCH] hz/intrusive_ptr.h: strncpy() string terminators When building the error message, ensure each strncpy() includes the null byte terminating the copied string, even though the first two will be immediately overwritten by the next part. Silences compiler warnings. --- src/hz/intrusive_ptr.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/hz/intrusive_ptr.h b/src/hz/intrusive_ptr.h index f95a91c..a456ef8 100644 --- a/src/hz/intrusive_ptr.h +++ b/src/hz/intrusive_ptr.h @@ -100,8 +100,8 @@ struct intrusive_ptr_error : virtual public std::exception { // from