mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-18 22:36:33 +00:00
Fix various leaks
Fix some leaks.
This commit is contained in:
parent
27f069b43c
commit
ae2521096a
3 changed files with 10 additions and 2 deletions
|
@ -86,6 +86,7 @@ send_response (GstRTSPClient *client, GstRTSPMessage *response)
|
|||
#endif
|
||||
|
||||
gst_rtsp_connection_send (client->connection, response, NULL);
|
||||
gst_rtsp_message_unset (response);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -496,6 +497,7 @@ handle_setup_request (GstRTSPClient *client, GstRTSPUrl *uri, GstRTSPMessage *re
|
|||
|
||||
/* serialize the server transport */
|
||||
trans_str = gst_rtsp_transport_as_text (st);
|
||||
gst_rtsp_transport_free (st);
|
||||
|
||||
/* construct the response now */
|
||||
code = GST_RTSP_STS_OK;
|
||||
|
@ -752,8 +754,12 @@ handle_client (GstRTSPClient *client)
|
|||
/* ERRORS */
|
||||
receive_failed:
|
||||
{
|
||||
gchar *str;
|
||||
str = gst_rtsp_strresult (res);
|
||||
g_message ("receive failed %d (%s), disconnect client %p", res,
|
||||
gst_rtsp_strresult (res), client);
|
||||
str, client);
|
||||
g_free (str);
|
||||
gst_rtsp_message_unset (&request);
|
||||
gst_rtsp_connection_close (client->connection);
|
||||
g_object_unref (client);
|
||||
return NULL;
|
||||
|
|
|
@ -85,7 +85,8 @@ gst_rtsp_media_finalize (GObject * obj)
|
|||
}
|
||||
g_array_free (media->streams, TRUE);
|
||||
|
||||
gst_object_unref (media->pipeline);
|
||||
if (media->pipeline)
|
||||
gst_object_unref (media->pipeline);
|
||||
|
||||
G_OBJECT_CLASS (gst_rtsp_media_parent_class)->finalize (obj);
|
||||
}
|
||||
|
|
|
@ -139,6 +139,7 @@ gst_rtsp_sdp_from_media (GstRTSPMedia *media)
|
|||
g_string_free (fmtp, TRUE);
|
||||
}
|
||||
gst_sdp_message_add_media (sdp, smedia);
|
||||
gst_sdp_media_free (smedia);
|
||||
}
|
||||
|
||||
return sdp;
|
||||
|
|
Loading…
Reference in a new issue