[Bug 667300] basesrc: fixes potential caps-memoryleak

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Thu Jan 12 11:28:00 PST 2012


https://bugzilla.gnome.org/show_bug.cgi?id=667300
  GStreamer | gstreamer (core) | git

--- Comment #3 from Håvard Graff (hgr) <havard.graff at tandberg.com> 2012-01-12 19:27:57 UTC ---
What if peercaps == GST_CAPS_ANY ?

if (peercaps && !gst_caps_is_any (peercaps)) {
    /* get intersection */
    caps =
        gst_caps_intersect_full (peercaps, thiscaps, GST_CAPS_INTERSECT_FIRST);
    GST_DEBUG_OBJECT (basesrc, "intersect: %" GST_PTR_FORMAT, caps);
    gst_caps_unref (peercaps);
  } else {
    /* no peer, work with our own caps then */
    caps = gst_caps_copy (thiscaps);
  }
}

It would go into the "else", and there peercaps would not be freed?

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list