[Bug 693324] New: Leak in gdppay when getting caps identical to your current ones

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Thu Feb 7 05:12:32 PST 2013


https://bugzilla.gnome.org/show_bug.cgi?id=693324
  GStreamer | gst-plugins-ugly | git

           Summary: Leak in gdppay when getting caps identical to your
                    current ones
    Classification: Platform
           Product: GStreamer
           Version: git
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: Normal
         Component: gst-plugins-ugly
        AssignedTo: gstreamer-bugs at lists.freedesktop.org
        ReportedBy: gnome at mithis.com
         QAContact: gstreamer-bugs at lists.freedesktop.org
     GNOME version: ---


Created an attachment (id=235397)
 View: https://bugzilla.gnome.org/attachment.cgi?id=235397
 Review: https://bugzilla.gnome.org/review?bug=693324&attachment=235397

Patch which fixes the leak.

This code leaks when the incoming caps are equal to this->caps;

    case GST_EVENT_CAPS:{
      gst_event_parse_caps (event, &caps);
      if (this->caps == NULL || !gst_caps_is_equal (this->caps, caps)) {
        GST_INFO_OBJECT (pad, "caps changed to %" GST_PTR_FORMAT, caps);
        gst_buffer_replace (&outbuffer, NULL);
        gst_caps_replace (&this->caps, caps);
        outbuffer = gst_gdp_buffer_from_caps (this, caps);
        if (outbuffer == NULL)
          goto no_buffer_from_caps;

        GST_BUFFER_DURATION (outbuffer) = 0;
        GST_BUFFER_FLAG_SET (outbuffer, GST_BUFFER_FLAG_HEADER);
        if (this->caps_buf)
          gst_buffer_unref (this->caps_buf);
        this->caps_buf = outbuffer;
        gst_gdp_pay_reset_streamheader (this);
      }
      break;
    }

-- 
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