close #333784 unref the result of gst_pad_get_parent() by: Christophe Fergeau.
[platform/upstream/gstreamer.git] / ext / jpeg / gstjpegenc.c
index 2485d2f..b76b620 100644 (file)
@@ -280,6 +280,7 @@ gst_jpegenc_getcaps (GstPad * pad)
           GST_STR_FOURCC ("I420"), NULL);
     }
   }
+  gst_object_unref (jpegenc);
 
   return caps;
 }
@@ -322,6 +323,8 @@ gst_jpegenc_setcaps (GstPad * pad, GstCaps * caps)
     gst_jpegenc_resync (jpegenc);
   }
 
+  gst_object_unref (jpegenc);
+
   return ret;
 }