ref/unref pad for unlink(unselected track) 13/106013/1 accepted/tizen/3.0/common/20161221.181302 accepted/tizen/3.0/ivi/20161221.010951 accepted/tizen/3.0/mobile/20161221.011618 accepted/tizen/3.0/tv/20161221.010741 accepted/tizen/3.0/wearable/20161221.011117 submit/tizen_3.0/20161220.100802
authorGilbok Lee <gilbok.lee@samsung.com>
Tue, 20 Dec 2016 07:49:15 +0000 (16:49 +0900)
committerGilbok Lee <gilbok.lee@samsung.com>
Tue, 20 Dec 2016 07:49:15 +0000 (16:49 +0900)
[Version] 0.1.13
[Profile] Common, Mobile, Wearable, TV
[Issue Type] Fix bugs

Change-Id: Ied7b7433f6fe875ab0ca3a250cf1301312b6f116

packaging/capi-mediademuxer.spec
src/port_gst/mediademuxer_port_gst.c

index 0ab08d5..2d0a380 100755 (executable)
@@ -1,6 +1,6 @@
 Name:       capi-mediademuxer
 Summary:    A Media Demuxer library in Tizen Native API
-Version:    0.1.12
+Version:    0.1.13
 Release:    1
 Group:      Multimedia/API
 License:    Apache-2.0
index 6f1dc88..bcd2a80 100755 (executable)
@@ -364,11 +364,11 @@ void __gst_free_stuct(track **head)
        track *temp = NULL;
        temp = *head;
        while (temp) {
-               /*
+
                if (temp->pad) {
                        MD_I("unref GST_PAD %p\n", temp->pad);
                        gst_object_unref(temp->pad);
-               } */
+               }
                if (temp->caps) {
                        MD_I("unref GST_PAD caps %p\n", temp->caps);
                        gst_caps_unref(temp->caps);
@@ -419,7 +419,9 @@ int __gst_add_track_info(GstPad *pad, GstCaps *caps, track **head,
        } else {
                MD_I("allocate memory %p", temp);
        }
-       temp->pad = pad;
+       memset(temp, 0x00, sizeof(track));
+
+       temp->pad = gst_object_ref(pad);
        temp->caps = gst_caps_ref(caps);
        temp->caps_string = gst_caps_to_string(caps);
        temp->next = NULL;