summaryrefslogtreecommitdiff
path: root/libavformat/os_support.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavformat/os_support.c')
-rw-r--r--libavformat/os_support.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/os_support.c b/libavformat/os_support.c
index 913ca539c8..e18704428b 100644
--- a/libavformat/os_support.c
+++ b/libavformat/os_support.c
@@ -58,7 +58,6 @@ int ff_win32_open(const char *filename_utf8, int oflag, int pmode)
#if CONFIG_NETWORK
#include <fcntl.h>
-#include <unistd.h>
#if !HAVE_POLL_H
#include <sys/time.h>
#if HAVE_WINSOCK2_H
@@ -253,7 +252,8 @@ const char *ff_gai_strerror(int ecode)
int ff_socket_nonblock(int socket, int enable)
{
#if HAVE_WINSOCK2_H
- return ioctlsocket(socket, FIONBIO, &enable);
+ u_long param = enable;
+ return ioctlsocket(socket, FIONBIO, &param);
#else
if (enable)
return fcntl(socket, F_SETFL, fcntl(socket, F_GETFL) | O_NONBLOCK);