summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntoine Jacoutot <ajacoutot@gnome.org>2014-10-05 08:50:22 +0200
committerStef Walter <stefw@redhat.com>2014-10-06 07:30:10 +0200
commitab778cc54c8671ba79cf4baca7be2608c7cce886 (patch)
treec7c1a7e90d28e5a72b9a91950d1ffeb8e392d985
parent80e4f6a6e04582fe11c98e6133e3e306e5556d8d (diff)
downloadp11-kit-ab778cc54c8671ba79cf4baca7be2608c7cce886.tar.gz
Unbreak build on OpenBSD
Add missing header for strdup(3). When EPROTO is not available, fallback to EIO. https://bugs.freedesktop.org/show_bug.cgi?id=84665
-rw-r--r--p11-kit/rpc-transport.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/p11-kit/rpc-transport.c b/p11-kit/rpc-transport.c
index 8c3fb0c..b3651ad 100644
--- a/p11-kit/rpc-transport.c
+++ b/p11-kit/rpc-transport.c
@@ -52,6 +52,7 @@
#include <fcntl.h>
#include <stdint.h>
#include <stdlib.h>
+#include <string.h>
#ifdef OS_UNIX
#include <sys/socket.h>
@@ -65,6 +66,10 @@
#include <winsock2.h>
#endif
+#ifndef EPROTO
+#define EPROTO EIO
+#endif
+
typedef struct {
/* Never changes */
int fd;