summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPeter Kjellerstedt <pkj@axis.com>2007-06-17 12:24:58 +0000
committerTim-Philipp Müller <tim@centricular.net>2007-06-17 12:24:58 +0000
commit9d2c01b5518be7e8f4757d1c60c254bceb014336 (patch)
tree9906f08080a724c3330bd3e1e70352bc1d95e0a8
parent6062b97aed905902a6aa1b6550041c844db38968 (diff)
gst/rtsp/rtspconnection.c: inet_ntoa() uses a static buffer internally, so we need to copy the returned string if we ...
Original commit message from CVS: Patch by: Peter Kjellerstedt <pkj at axis com> * gst/rtsp/rtspconnection.c: (rtsp_connection_connect), (rtsp_connection_free): inet_ntoa() uses a static buffer internally, so we need to copy the returned string if we want to store it for later (#447961).
-rw-r--r--ChangeLog9
-rw-r--r--gst/rtsp/rtspconnection.c3
2 files changed, 11 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index eb461b47..bbdc89fd 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2007-06-17 Tim-Philipp Müller <tim at centricular dot net>
+
+ Patch by: Peter Kjellerstedt <pkj at axis com>
+
+ * gst/rtsp/rtspconnection.c: (rtsp_connection_connect),
+ (rtsp_connection_free):
+ inet_ntoa() uses a static buffer internally, so we need to copy the
+ returned string if we want to store it for later (#447961).
+
2007-06-15 Jan Schmidt <thaytan@mad.scientist.com>
* win32/vs6/autogen.dsp:
diff --git a/gst/rtsp/rtspconnection.c b/gst/rtsp/rtspconnection.c
index f96caf4d..e8c1ceec 100644
--- a/gst/rtsp/rtspconnection.c
+++ b/gst/rtsp/rtspconnection.c
@@ -264,7 +264,7 @@ rtsp_connection_connect (RTSPConnection * conn, GTimeVal * timeout)
done:
conn->fd = fd;
- conn->ip = ip;
+ conn->ip = g_strdup (ip);
return RTSP_OK;
@@ -1030,6 +1030,7 @@ rtsp_connection_free (RTSPConnection * conn)
g_timer_destroy (conn->timer);
g_free (conn->username);
g_free (conn->passwd);
+ g_free (conn->ip);
g_free (conn);