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 752496 - dashdemux: illegal memory access when the list of S nodes is greater than the list of SegmentURL nodes
dashdemux: illegal memory access when the list of S nodes is greater than the...
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
git master
Other Linux
: Normal normal
: 1.7.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2015-07-16 15:02 UTC by Florin Apostol
Modified: 2015-10-29 11:05 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
proposed fix and unit tests (4.00 KB, patch)
2015-07-16 15:04 UTC, Florin Apostol
committed Details | Review

Description Florin Apostol 2015-07-16 15:02:05 UTC
When building the media segment list using a SegmentList node, the 
gst_mpd_client_setup_representation function will iterate through the 
list of S nodes and for each S node will expect to find a matching SegmentUrl node. If one does not exist, the code makes an illegal memory access when it tries to access a NULL SegmentURL pointer.
Comment 1 Florin Apostol 2015-07-16 15:04:10 UTC
Created attachment 307567 [details] [review]
proposed fix and unit tests
Comment 2 Thiago Sousa Santos 2015-07-27 15:20:40 UTC
Looks correct.

It also concerns me about the handling of the repeated S entries and matching those to the SegmentURLs as well. Looks like the same URL will be used for all the repetitions of an S node. I wonder what the spec has to say about it.
Comment 3 Florin Apostol 2015-07-28 09:58:13 UTC
the spec is not very clear. I expected the repetitions to target different SergmentURLs, (eg a segment timeline with r=2 should have 3 segment URLs, because segment timeline is just a compressed form to avoid specifying the same duration for each segment) but it seems the implementation is different and just repeats the same segment URL over and over. Personally I think the implementation is wrong, but I don't have any examples to prove it.
Comment 4 Vincent Penquerc'h 2015-10-29 11:05:10 UTC
commit 566e84cec1b372069b00b3594d1fa592ddd0c12c
Author: Florin Apostol <florin.apostol@oregan.net>
Date:   Wed Oct 28 17:02:51 2015 +0000

    dashdemux: fixed crash when segment timeline list is greater than segment url list
    
    When building the media segment list using a SegmentList node, the
    gst_mpd_client_setup_representation function will iterate through the
    list of S nodes and will expect to find a matching SegmentUrl node. If
    one does not exist, the code made an illegal memory access.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=752496