]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
nptl_db/thread_dbP.h: fix warn unused result
authorFrédéric Bérat <fberat@redhat.com>
Thu, 1 Jun 2023 14:27:44 +0000 (16:27 +0200)
committerSiddhesh Poyarekar <siddhesh@sourceware.org>
Thu, 1 Jun 2023 17:00:03 +0000 (13:00 -0400)
Fix unused result warnings, detected when _FORTIFY_SOURCE is enabled in
glibc.
Reviewed-by: Siddhesh Poyarekar <siddhesh@sourceware.org>
nptl_db/thread_dbP.h

index 884572210934362a38ecd021d5aee0446cf42f0a..b52c254300db2ad6c49e4ae71d7b05feab3a5e35 100644 (file)
@@ -61,7 +61,9 @@ enum
 
 /* Comment out the following for less verbose output.  */
 #ifndef NDEBUG
-# define LOG(c) if (__td_debug) write (2, c "\n", strlen (c "\n"))
+# define LOG(c) \
+  if (__td_debug) \
+    assert (write (2, c "\n", strlen (c "\n")) == strlen (c "\n"))
 extern int __td_debug attribute_hidden;
 #else
 # define LOG(c)