From 39dba5aa1b919c4b40619895bf3b4936fbe29deb Mon Sep 17 00:00:00 2001 From: Martin Storsjö Date: Mon, 25 Jun 2012 00:39:57 +0300 Subject: network: Include unistd.h from network.h MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This heaader is required for close() for sockets in network code. For winsock, the equivalent function is defined in the winsock2.h header. This avoids having the HAVE_UNISTD_H in all files dealing with raw sockets. Signed-off-by: Martin Storsjö --- libavformat/network.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'libavformat/network.h') diff --git a/libavformat/network.h b/libavformat/network.h index 1dc9deb675..3e4422e4c2 100644 --- a/libavformat/network.h +++ b/libavformat/network.h @@ -27,6 +27,10 @@ #include "libavutil/error.h" #include "os_support.h" +#if HAVE_UNISTD_H +#include +#endif + #if HAVE_WINSOCK2_H #include #include -- cgit v1.2.3