diff options
author | Uoti Urpala <uau@glyph.nonexistent.invalid> | 2008-09-03 10:16:30 +0300 |
---|---|---|
committer | Uoti Urpala <uau@glyph.nonexistent.invalid> | 2008-09-03 10:16:30 +0300 |
commit | b56858342fdbe48489618107df75e5bd0451eb0b (patch) | |
tree | 5d41ef858502bae99dcbebdd728d42a6040adb03 /stream/stream.c | |
parent | 8ea7eb77fc7ba8bd0b596ea32ee60909a012828f (diff) | |
parent | bae94777d7ddaa2d4763507fdb93b9520327c9d1 (diff) | |
download | mpv-b56858342fdbe48489618107df75e5bd0451eb0b.tar.bz2 mpv-b56858342fdbe48489618107df75e5bd0451eb0b.tar.xz |
Merge svn changes up to r27514
Diffstat (limited to 'stream/stream.c')
-rw-r--r-- | stream/stream.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/stream/stream.c b/stream/stream.c index 47d55be71f..1431fa123a 100644 --- a/stream/stream.c +++ b/stream/stream.c @@ -14,16 +14,14 @@ #include "config.h" -#ifndef HAVE_WINSOCK2 -#define closesocket close -#else +#ifdef HAVE_WINSOCK2_H #include <winsock2.h> #endif #include "mp_msg.h" #include "help_mp.h" #include "osdep/shmem.h" - +#include "network.h" #include "stream.h" #include "libmpdemux/demuxer.h" @@ -408,7 +406,7 @@ stream_t* new_stream(int fd,int type){ if(s==NULL) return NULL; memset(s,0,sizeof(stream_t)); -#ifdef HAVE_WINSOCK2 +#ifdef HAVE_WINSOCK2_H { WSADATA wsdata; int temp = WSAStartup(0x0202, &wsdata); // there might be a better place for this (-> later) @@ -443,7 +441,7 @@ void free_stream(stream_t *s){ closesocket(s->fd); else close(s->fd); } -#ifdef HAVE_WINSOCK2 +#ifdef HAVE_WINSOCK2_H mp_msg(MSGT_STREAM,MSGL_V,"WINSOCK2 uninit\n"); WSACleanup(); // there might be a better place for this (-> later) #endif |