summaryrefslogtreecommitdiffstats
path: root/usr.sbin/mkuboot
diff options
context:
space:
mode:
authormpi <mpi@openbsd.org>2017-10-29 08:45:53 +0000
committermpi <mpi@openbsd.org>2017-10-29 08:45:53 +0000
commit9f79a69831e4879318a9c62b1da26ebbbfc9edc0 (patch)
tree5e215bd16f9948a8234e3853e6ce87ebac259c1c /usr.sbin/mkuboot
parentSync example with description. (diff)
downloadwireguard-openbsd-9f79a69831e4879318a9c62b1da26ebbbfc9edc0.tar.xz
wireguard-openbsd-9f79a69831e4879318a9c62b1da26ebbbfc9edc0.zip
Prefer <elf.h> to the non portable <sys/exec_elf.h>.
ok jca@, deraadt@
Diffstat (limited to 'usr.sbin/mkuboot')
-rw-r--r--usr.sbin/mkuboot/copy_elf.c4
-rw-r--r--usr.sbin/mkuboot/mkuboot.c5
2 files changed, 5 insertions, 4 deletions
diff --git a/usr.sbin/mkuboot/copy_elf.c b/usr.sbin/mkuboot/copy_elf.c
index 60e5e77e531..f301bdd10dc 100644
--- a/usr.sbin/mkuboot/copy_elf.c
+++ b/usr.sbin/mkuboot/copy_elf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: copy_elf.c,v 1.5 2014/01/01 09:24:54 mcbride Exp $ */
+/* $OpenBSD: copy_elf.c,v 1.6 2017/10/29 08:45:53 mpi Exp $ */
/*
* Copyright (c) 2013 Miodrag Vallat.
@@ -22,7 +22,7 @@
#include <stdlib.h>
#include <string.h>
-#include <sys/exec_elf.h>
+#include <elf.h>
#if defined(ELFSIZE) && (ELFSIZE == 32)
#define elfoff2h(x) letoh32(x)
diff --git a/usr.sbin/mkuboot/mkuboot.c b/usr.sbin/mkuboot/mkuboot.c
index 5a1b764319b..c7fb31de823 100644
--- a/usr.sbin/mkuboot/mkuboot.c
+++ b/usr.sbin/mkuboot/mkuboot.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mkuboot.c,v 1.7 2016/12/20 11:27:11 jsg Exp $ */
+/* $OpenBSD: mkuboot.c,v 1.8 2017/10/29 08:45:53 mpi Exp $ */
/*
* Copyright (c) 2008 Mark Kettenis
@@ -18,6 +18,8 @@
#include <sys/types.h>
#include <sys/stat.h>
+
+#include <elf.h>
#include <err.h>
#include <fcntl.h>
#include <stdint.h>
@@ -27,7 +29,6 @@
#include <time.h>
#include <unistd.h>
#include <zlib.h>
-#include <sys/exec_elf.h>
#define IH_OS_OPENBSD 1 /* OpenBSD */
#define IH_OS_LINUX 5 /* Linux */