[gupnp-tools] av-cp: Add missing free
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gupnp-tools] av-cp: Add missing free
- Date: Mon, 25 Apr 2016 21:37:37 +0000 (UTC)
commit dfe463abc27ca6446de5d8e8a2f5e9917aa1a66e
Author: Jens Georg <mail jensge org>
Date: Sun Apr 3 18:40:18 2016 +0200
av-cp: Add missing free
Signed-off-by: Jens Georg <mail jensge org>
src/av-cp/server-device.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/av-cp/server-device.c b/src/av-cp/server-device.c
index 73ed478..2a89e42 100644
--- a/src/av-cp/server-device.c
+++ b/src/av-cp/server-device.c
@@ -158,7 +158,7 @@ av_cp_media_server_on_get_sort_caps (GUPnPServiceProxy *proxy,
g_warning ("Failed to get sort caps from server: %s",
error->message);
g_error_free (error);
- } else {
+ } else if (sort_caps != NULL) {
GString *default_sort_order = g_string_new (NULL);
if (strstr (sort_caps, "upnp:class") != NULL) {
g_string_append (default_sort_order, "+upnp:class,");
@@ -170,6 +170,8 @@ av_cp_media_server_on_get_sort_caps (GUPnPServiceProxy *proxy,
self->priv->default_sort_order =
g_string_free (default_sort_order, FALSE);
+
+ g_free (sort_caps);
}
self->priv->state = INITIALIZED;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]