]> git.armaanb.net Git - opendoas.git/commitdiff
libopenbsd: minor cleanup
authorDuncaen <mail@duncano.de>
Wed, 30 Jan 2019 21:29:11 +0000 (22:29 +0100)
committerDuncaen <mail@duncano.de>
Wed, 30 Jan 2019 22:19:17 +0000 (23:19 +0100)
libopenbsd/closefrom.c
libopenbsd/errc.c
libopenbsd/execvpe.c
libopenbsd/openbsd.h
libopenbsd/pledge-noop.c [deleted file]
libopenbsd/verrc.c

index b56476a2d85895d1d378ffeeba09da892552ce3f..ef7d611b003853b7955b7ec838fa0a9600ea7ea5 100644 (file)
@@ -69,7 +69,7 @@ void
 closefrom(int lowfd)
 {
     long fd, maxfd;
-#if defined(HAVE_DIRFD) && defined(HAVE_PROC_PID)
+#if defined(HAVE_PROC_PID)
     char fdpath[PATH_MAX], *endp;
     struct dirent *dent;
     DIR *dirp;
index 8e8474b70a6baf1e80f84c010ac3d93a7bee7763..37eff0fd1f49e78f4e999055f558e30c579490f9 100644 (file)
  * SUCH DAMAGE.
  */
 
+#include "includes.h"
+
 #include <err.h>
 #include <stdarg.h>
 
-#include "openbsd.h"
-
 __dead void
 errc(int eval, int code, const char *fmt, ...)
 {
index 4ddad3efe4e84ec6edeb5d5d2c9e63262be0dec3..c3238eaa17d727441908dd3c2dbfbd43cb1186a0 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: exec.c,v 1.20 2013/01/08 02:26:09 deraadt Exp $ */
+/*     $OpenBSD: exec.c,v 1.23 2016/03/13 18:34:20 guenther Exp $ */
 /*-
  * Copyright (c) 1991, 1993
  *     The Regents of the University of California.  All rights reserved.
@@ -28,6 +28,8 @@
  * SUCH DAMAGE.
  */
 
+#include "includes.h"
+
 #include <sys/types.h>
 #include <sys/uio.h>
 
@@ -40,8 +42,6 @@
 #include <string.h>
 #include <unistd.h>
 
-#include "includes.h"
-
 int
 execvpe(const char *name, char *const *argv, char *const *envp)
 {
index d9d3c99bfa7b69d2cbb18393b6a3d86966db68ac..793d9bf39363668845867b3cd35e827993e8eea4 100644 (file)
@@ -4,8 +4,6 @@
 #include <stdarg.h>
 #include <sys/types.h>
 
-#include "readpassphrase.h"
-
 /* API definitions lifted from OpenBSD src/include */
 
 /* pwd.h */
diff --git a/libopenbsd/pledge-noop.c b/libopenbsd/pledge-noop.c
deleted file mode 100644 (file)
index 0a1b610..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-#include "openbsd.h"
-
-int
-pledge(__UNUSED const char *promises, __UNUSED const char *paths[])
-{
-       return 0;
-}
index e00fcd178e8000213af9f1647040bcc597393374..15400bc1069d8b0ff7c03ed1f401b67b51be1599 100644 (file)
  * SUCH DAMAGE.
  */
 
+#include "includes.h"
+
 #include <err.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
 #include <stdarg.h>
 
-#include "openbsd.h"
-
 __dead void
 verrc(int eval, int code, const char *fmt, va_list ap)
 {