[gstreamer-bugs] [Bug 432755] New: videorate: leaked buffer on failure of gst_video_rate_flush_prev()

GStreamer (bugzilla.gnome.org) bugzilla-daemon at bugzilla.gnome.org
Mon Apr 23 14:11:18 PDT 2007

If you have any questions why you received this email, please see the text at
the end of this email. Replies to this email are NOT read, please see the text
at the end of this email. You can add comments to this bug at:

  GStreamer | gst-plugins-base | Ver: 0.10.x
           Summary: videorate: leaked buffer on failure of
           Product: GStreamer
           Version: 0.10.x
          Platform: Other
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: Normal
         Component: gst-plugins-base
        AssignedTo: gstreamer-bugs at lists.sourceforge.net
        ReportedBy: dcbw at redhat.com
         QAContact: gstreamer-bugs at lists.sourceforge.net
                CC: thomas at apestaart.org
     GNOME version: Unspecified
   GNOME milestone: Unspecified

Reproducible using this pipeline:

v4l2src ! videorate ! video/x-raw-yuv,framerate=5/1 ! ffmpegcolorspace !
videoflip ! fakesink

and this one:

v4l2src ! videorate ! video/x-raw-yuv,framerate=5/1 ! ffmpegcolorspace !
theoraenc ! fakesink

1) gst_video_rate_chain() gets a new buffer
2) gst_video_rate_chain() executes:
        if ((res = gst_video_rate_flush_prev (videorate)) != GST_FLOW_OK)
3) during the call to gst_video_rate_flush_prev(), the user hits Ctl+C and the
pipeline gets set to PAUSED
4) The PAUSED pipeline state causes this statement in
gst_video_rate_flush_prev() to return something other than GST_FLOW_OK:
        res = gst_pad_push (videorate->srcpad, outbuf);
5) gst_video_rate_flush_prev() returns the ! GST_FLOW_OK result
6) gst_video_rate_chain() then executes the following, jumping to the 'done'
        if ((res = gst_video_rate_flush_prev (videorate)) != GST_FLOW_OK)
           goto done;
7) gst_video_rate_chain() returns, leaking 'buffer'

Not sure what the best fix is, whether to just unref the buffer on error, or to
do something with swap_prev() or what.

See http://bugzilla.gnome.org/page.cgi?id=email.html for more info about why you received
this email, why you can't respond via email, how to stop receiving
emails (or reduce the number you receive), and how to contact someone
if you are having problems with the system.

You can add comments to this bug at http://bugzilla.gnome.org/show_bug.cgi?id=432755.

More information about the Gstreamer-bugs mailing list