From e45873c6ec1877656d801c49540c8a27e3dc9780 Mon Sep 17 00:00:00 2001 From: Thibault Saunier Date: Wed, 8 Nov 2017 12:46:44 -0300 Subject: [PATCH] taglist: Avoid assertions when getting tag nick from unregister tag With serialized GstDiscovererInfos we might end up trying to use tags that have not been registered. --- gst/gsttaglist.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/gst/gsttaglist.c b/gst/gsttaglist.c index dd036de0e7..f1940d985c 100644 --- a/gst/gsttaglist.c +++ b/gst/gsttaglist.c @@ -613,7 +613,11 @@ gst_tag_get_nick (const gchar * tag) g_return_val_if_fail (tag != NULL, NULL); info = gst_tag_lookup (tag); - g_return_val_if_fail (info != NULL, NULL); + if (!info) { + GST_WARNING ("Uknown tag: %s", tag); + + return tag; + } return info->nick; }