summaryrefslogtreecommitdiffstats
path: root/stream/tcp.c
diff options
context:
space:
mode:
authorUoti Urpala <uau@glyph.nonexistent.invalid>2009-07-07 02:56:01 +0300
committerUoti Urpala <uau@glyph.nonexistent.invalid>2009-07-07 02:56:01 +0300
commita2037a2effbd4622d0e8336245a9b14c3f886bde (patch)
treebd2face6dd36d2663197b23a33da9e9b2814f70c /stream/tcp.c
parent0c2773a709276681575d2507aa60ee85c2d0b850 (diff)
parent43079c51daa8c12b0a44e5ad8022c979dd9e8336 (diff)
downloadmpv-a2037a2effbd4622d0e8336245a9b14c3f886bde.tar.bz2
mpv-a2037a2effbd4622d0e8336245a9b14c3f886bde.tar.xz
Merge svn changes up to r29412
Diffstat (limited to 'stream/tcp.c')
-rw-r--r--stream/tcp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/stream/tcp.c b/stream/tcp.c
index 7566f5b309..0291fba544 100644
--- a/stream/tcp.c
+++ b/stream/tcp.c
@@ -33,6 +33,7 @@
#include "network.h"
#include "stream.h"
#include "tcp.h"
+#include "libavutil/avstring.h"
/* IPv6 options */
int network_prefer_ipv4 = 0;
@@ -163,7 +164,7 @@ connect2Server_with_af(char *host, int port, int af,int verb) {
}
#if HAVE_INET_ATON || defined(HAVE_WINSOCK2_H)
- strncpy( buf, inet_ntoa( *((struct in_addr*)our_s_addr) ), 255);
+ av_strlcpy( buf, inet_ntoa( *((struct in_addr*)our_s_addr) ), 255);
#else
inet_ntop(af, our_s_addr, buf, 255);
#endif