]> Savannah Git Hosting - gnulib.git/commitdiff
signal-h tests: Check that SIG2STR_MAX is properly defined.
authorCollin Funk <collin.funk1@gmail.com>
Sun, 29 Dec 2024 19:56:28 +0000 (11:56 -0800)
committerCollin Funk <collin.funk1@gmail.com>
Sun, 29 Dec 2024 19:56:28 +0000 (11:56 -0800)
* modules/signal-h-tests (Depends-on): Add assert-h.
* tests/test-signal-h.c: Check that SIG2STR_MAX is defined to a
positive integer.

ChangeLog
modules/signal-h-tests
tests/test-signal-h.c

index 8fcb0f9a46054d145469a90a084d4f9f115251bf..a0d18345f24dfee03811b89fa3425fbb717fcfb1 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2024-12-29  Collin Funk  <collin.funk1@gmail.com>
 
+       signal-h tests: Check that SIG2STR_MAX is properly defined.
+       * modules/signal-h-tests (Depends-on): Add assert-h.
+       * tests/test-signal-h.c: Check that SIG2STR_MAX is defined to a
+       positive integer.
+
        sig2str tests: Add signature check.
        * modules/sig2str-tests (Files): Add tests/signature.h.
        * tests/test-sig2str.c: Include signal.h instead of sig2str.h. Check the
index dab83e9edf0f84c30f399c2fca654dd117b17baf..1228f7c1df3ca46412e904e5b4f9a26d33c9fdf2 100644 (file)
@@ -2,6 +2,7 @@ Files:
 tests/test-signal-h.c
 
 Depends-on:
+assert-h
 signal-h-c++-tests
 
 configure.ac:
index c4b322078762ea51f75c06f84549d1eb0eeb324c..4268fa4d56185a4f52014c01f726434319feafb2 100644 (file)
@@ -20,6 +20,9 @@
 
 #include <signal.h>
 
+/* Check that SIG2STR_MAX is defined to a positive integer.  */
+static_assert (0 < SIG2STR_MAX);
+
 /* Check for required types.  */
 struct
 {