After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 696032 - mpegtsmux: Downstream force-key-unit events are being assigned the wrong "count"
mpegtsmux: Downstream force-key-unit events are being assigned the wrong "count"
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
1.0.5
Other All
: Normal normal
: 1.5.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2013-03-18 08:14 UTC by Anton Gritsay
Modified: 2015-02-03 20:39 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Proposed fix (924 bytes, patch)
2013-03-18 08:15 UTC, Anton Gritsay
committed Details | Review

Description Anton Gritsay 2013-03-18 08:14:20 UTC
In mpegtsmux/mpegtsmux.c function check_pending_key_unit_event() always assumes that the pending_event is upstream, which is not always the case - function mpegtsmux_sink_event() assigns an event of downstream type to mux->force_key_unit_event, which later gets passed to check_pending_key_unit_event().

In case when the actual event is downstream, parsing it as an upstream one doesn't work right, in particular it assigns wrong values to count variable. In my setup those count values were changing unpredictably or in many cases not changing in subsequent FKU events, and thus propagation of that FKU event downstream would stop.

Attached patch fixes the issue.

Please note also that there is probably an analogous problem in videoparsers/gsth264parse.c which has almost identical implementation of check_pending_key_unit_event().
Comment 1 Anton Gritsay 2013-03-18 08:15:12 UTC
Created attachment 239097 [details] [review]
Proposed fix
Comment 2 Thiago Sousa Santos 2015-02-03 20:38:02 UTC
Thanks for the patch. For future patches, please commit in git and use git format-patch to generate the patch to attach here. It allows for easier merge and review.

commit 77bafb4dbca76fe160acd76a8bd3811e9c57cbaf
Author: Anton Gritsay <anton@angri.ru>
Date:   Mon Mar 18 08:15:00 2013 +0000

    mpegtsmux: parse force key unit events with the correct function
    
    Otherwise it won't be parsed and bogus values would be used.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=696032