rtsp: Plug a memory leak.
authorPeter Kjellerstedt <pkj@axis.com>
Tue, 9 Jun 2009 14:28:20 +0000 (16:28 +0200)
committerPeter Kjellerstedt <pkj@axis.com>
Tue, 9 Jun 2009 14:28:20 +0000 (16:28 +0200)
Free memory related to any partially read and/or written RTSP messages.

gst-libs/gst/rtsp/gstrtspconnection.c

index e7b57d9..066734e 100644 (file)
@@ -2811,10 +2811,13 @@ gst_rtsp_source_finalize (GSource * source)
   GstRTSPWatch *watch = (GstRTSPWatch *) source;
 
   build_reset (&watch->builder);
+  gst_rtsp_message_unset (&watch->message);
 
   g_async_queue_unref (watch->messages);
   watch->messages = NULL;
 
+  g_free (watch->write_data);
+
   if (watch->notify)
     watch->notify (watch->user_data);
 }