Paul Eggert wrote on 2022-03-23:
> The 3rd patch tests for glibc bug 25659 ...

This patch produces a warning

../../gltests/test-glob.c: In function 'main':
../../gltests/test-glob.c:77:17: warning: implicit declaration of function 
'creat' [-Wimplicit-function-declaration]
   77 |       && close (creat (BASE "globfile", 0666)) == 0)
      |                 ^~~~~

Fixed as follows.


2022-05-14  Bruno Haible  <br...@clisp.org>

        glob tests: Fix a warning (regression from 2022-03-23).
        * tests/test-glob.c: Include <fcntl.h>.
        * modules/glob-tests (Depends-on): Add fcntl-h.

diff --git a/modules/glob-tests b/modules/glob-tests
index ec519cf38d..afce2dbca0 100644
--- a/modules/glob-tests
+++ b/modules/glob-tests
@@ -4,6 +4,7 @@ tests/signature.h
 tests/macros.h
 
 Depends-on:
+fcntl-h
 symlink
 
 configure.ac:
diff --git a/tests/test-glob.c b/tests/test-glob.c
index 568acf14b7..61c7ca4583 100644
--- a/tests/test-glob.c
+++ b/tests/test-glob.c
@@ -26,6 +26,7 @@ SIGNATURE_CHECK (glob, int, (char const *, int, int (*) (char 
const *, int),
 SIGNATURE_CHECK (globfree, void, (glob_t *));
 
 #include <errno.h>
+#include <fcntl.h>
 #include <string.h>
 #include <unistd.h>
 




Reply via email to