]> Savannah Git Hosting - gnulib.git/commitdiff
Fix -Wundef warning in user-included header lib/cdefs.h.
authorTim Rühsen <tim.ruehsen@gmx.de>
Wed, 3 Jan 2018 10:50:07 +0000 (11:50 +0100)
committerBruno Haible <bruno@clisp.org>
Thu, 4 Jan 2018 09:59:48 +0000 (10:59 +0100)
* lib/cdefs.h: Check if defined before using __USE_FORTIFY_LEVEL.

ChangeLog
lib/cdefs.h

index f934336d55e88965510c4c20fc4d11b7f61721bb..3f2d8ce5b288b695e5784fe17a025cdedf1ba3cc 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2018-01-04  Tim Rühsen  <tim.ruehsen@gmx.de>
+
+       Fix -Wundef warning in user-included header lib/cdefs.h.
+       * lib/cdefs.h: Check if defined before using __USE_FORTIFY_LEVEL.
+
 2018-01-04  Bruno Haible  <bruno@clisp.org>
 
        pthread_sigmask: Avoid compilation error on mingw.
index 9ed0259dce1bb2efbee7ece07302a2da983e691a..f6c20fe2ed3280a17a9437263d2ceef27cd9006b 100644 (file)
 #if __GNUC_PREREQ (3,4)
 # define __attribute_warn_unused_result__ \
    __attribute__ ((__warn_unused_result__))
-# if __USE_FORTIFY_LEVEL > 0
+# if defined __USE_FORTIFY_LEVEL && __USE_FORTIFY_LEVEL > 0
 #  define __wur __attribute_warn_unused_result__
 # endif
 #else