aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBjörn-Egil Dahlberg <[email protected]>2016-06-07 16:07:09 +0200
committerBjörn-Egil Dahlberg <[email protected]>2016-06-07 16:07:09 +0200
commite2bb65e6354123ac5d0ec9e2c1de6a92ae581161 (patch)
tree42c5415a5f4e966aecc60cd32fe7dcfd8a5d8566
parent4c6ccf1c2f13d4b6ea34bc0eecc8a772cb38e80a (diff)
downloadotp-e2bb65e6354123ac5d0ec9e2c1de6a92ae581161.tar.gz
otp-e2bb65e6354123ac5d0ec9e2c1de6a92ae581161.tar.bz2
otp-e2bb65e6354123ac5d0ec9e2c1de6a92ae581161.zip
erl_interface: Let struct iovec * be visible
-rw-r--r--lib/erl_interface/src/misc/ei_portio.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/erl_interface/src/misc/ei_portio.h b/lib/erl_interface/src/misc/ei_portio.h
index a14fdbd7d1..fbb61b0ccf 100644
--- a/lib/erl_interface/src/misc/ei_portio.h
+++ b/lib/erl_interface/src/misc/ei_portio.h
@@ -21,6 +21,12 @@
*/
#ifndef _EI_PORTIO_H
#define _EI_PORTIO_H
+#if !defined(__WIN32__) || !defined(VXWORKS)
+#ifdef HAVE_WRITEV
+/* Declaration of struct iovec *iov should be visible in this scope. */
+#include <sys/uio.h>
+#endif
+#endif
int ei_accept_t(int fd, void *addr, void *addrlen, unsigned ms);
int ei_connect_t(int fd, void *sinp, int sin_siz, unsigned ms);
@@ -29,8 +35,7 @@ int ei_write_fill(int fd, const char *buf, int len);
int ei_read_fill_t(int fd, char* buf, int len, unsigned ms);
int ei_write_fill_t(int fd, const char *buf, int len, unsigned ms);
#ifdef HAVE_WRITEV
-int ei_writev_fill_t(int fd, const struct iovec *iov, int iovcnt,
- unsigned ms);
+int ei_writev_fill_t(int fd, const struct iovec *iov, int iovcnt, unsigned ms);
#endif
#endif /* _EI_PORTIO_H */