diff options
author | ben <ben@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-06-27 19:18:52 +0000 |
---|---|---|
committer | ben <ben@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-06-27 19:18:52 +0000 |
commit | 62a3993cc8a96a42de6dfc148a8c76fc2c996e8c (patch) | |
tree | 13cb1fa944197a87a607a29e0c008beda2c1f467 /libmpdemux | |
parent | 808992064d37531d846071dc153c0f3ee1a3082c (diff) |
network code portability for win32
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@18840 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r-- | libmpdemux/librtsp/rtsp_rtp.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/libmpdemux/librtsp/rtsp_rtp.c b/libmpdemux/librtsp/rtsp_rtp.c index d7fa21968c..45314e78f9 100644 --- a/libmpdemux/librtsp/rtsp_rtp.c +++ b/libmpdemux/librtsp/rtsp_rtp.c @@ -381,8 +381,17 @@ is_multicast_address (char *addr) return -1; sin.sin_family = AF_INET; - inet_pton (AF_INET, addr, &sin.sin_addr); +#ifndef HAVE_WINSOCK2 +#ifdef USE_ATON + inet_aton (addr, &sin.sin_addr); +#else + inet_pton (AF_INET, addr, &sin.sin_addr); +#endif +#else + sin.sin_addr.s_addr = htonl (INADDR_ANY); +#endif + if ((ntohl (sin.sin_addr.s_addr) >> 28) == 0xe) return 1; |