]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
Add includes.h to compat tests.
authorDarren Tucker <dtucker@dtucker.net>
Tue, 10 Aug 2021 23:21:09 +0000 (09:21 +1000)
committerDarren Tucker <dtucker@dtucker.net>
Tue, 10 Aug 2021 23:21:09 +0000 (09:21 +1000)
On platforms where closefrom returns void (eg glibc>=2.34) the prototype
for closefrom in its compat tests would cause compile errors.  Remove
this and have the tests pull in the compat headers in the same way as
the main code.  bz#3336.

openbsd-compat/regress/Makefile.in
openbsd-compat/regress/closefromtest.c
openbsd-compat/regress/opensslvertest.c
openbsd-compat/regress/snprintftest.c
openbsd-compat/regress/strduptest.c
openbsd-compat/regress/strtonumtest.c
openbsd-compat/regress/utimensattest.c

index c5aae61e2a42f427c36f8257bbd771567c0bb3b5..dd8cdc4b7e7adbcd30ed96fdcbf229f454314c05 100644 (file)
@@ -7,7 +7,7 @@ VPATH=@srcdir@
 CC=@CC@
 LD=@LD@
 CFLAGS=@CFLAGS@
-CPPFLAGS=-I. -I.. -I$(srcdir) -I$(srcdir)/.. @CPPFLAGS@ @DEFS@
+CPPFLAGS=-I. -I.. -I../.. -I$(srcdir) -I$(srcdir)/.. -I$(srcdir)/../.. @CPPFLAGS@ @DEFS@
 EXEEXT=@EXEEXT@
 LIBCOMPAT=../libopenbsd-compat.a
 LIBS=@LIBS@
index 82ffeb9a761394194d32bdc5e02716ff1c433e4f..7a69fb2b1a4e6fa6ffc520825acba348627cc9b5 100644 (file)
@@ -14,6 +14,8 @@
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
+#include "includes.h"
+
 #include <sys/types.h>
 #include <sys/stat.h>
 
@@ -24,8 +26,6 @@
 
 #define NUM_OPENS 10
 
-int closefrom(int);
-
 void
 fail(char *msg)
 {
index 5d019b5981a22b1f1f4504f657efe94110b5e76b..43825b24c3eb04cd59f328afe58dd44ee914e9c5 100644 (file)
@@ -14,6 +14,8 @@
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
+#include "includes.h"
+
 #include <stdio.h>
 #include <stdlib.h>
 
index 6dc2e222a67c38d8fce681811a6ea29dc166a3bb..a3134db1ca947423d77d168e62a5858f64f35f14 100644 (file)
@@ -17,6 +17,8 @@
 
 #define BUFSZ 2048
 
+#include "includes.h"
+
 #include <sys/types.h>
 #include <stdlib.h>
 #include <stdio.h>
index 7f6d779bedb3bdf0627fbe7c56847f42f972ed3d..8a3ccf77169f9b6dee3c2cdb36cd2d49ca6550a1 100644 (file)
@@ -14,6 +14,8 @@
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
+#include "includes.h"
+
 #include <stdlib.h>
 #include <string.h>
 
index 50ca5bd22d4e1f31c128171af9af1928bfdb073f..46bd2b916494d113839a14f0ebd1ae89a1931b81 100644 (file)
@@ -17,6 +17,8 @@
 
 /* OPENBSD ORIGINAL: regress/lib/libc/strtonum/strtonumtest.c */
 
+#include "includes.h"
+
 #include <limits.h>
 #include <stdio.h>
 #include <stdlib.h>
index 24312e5d828fa421898bbdc98e799f672a037e14..bbc66c48523e1caa46c55cb293bdf9b167538e61 100644 (file)
@@ -14,6 +14,8 @@
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
+#include "includes.h"
+
 #include <sys/types.h>
 #include <sys/stat.h>