Skip to content

SegmentBase getSegmentTimeUs does not perform a bounds check, results in out of bounds error #11014

Closed

Description

@kamaroyl

ExoPlayer Version

2.18.3

Devices that reproduce the issue

  • Pixel 6 Pro

Devices that do not reproduce the issue

No response

Reproducible in the demo app?

Yes

Reproduction steps

Provide a dash manifest with an empty segmentTimeline, getSegmentTimeUs attempts to index into segmentTimeline which is empty, resulting in an out of bounds error.

Expected result

Something other than an out of bounds error, perhaps an error or warn that the segmentTimeline is empty.

Actual result

Index out of bounds exception

Media

This was the mpd in question. May violate DASH spec, but a more useful error would be appreciated
DASH_EXAMPLE.zip

Bug Report

  • You will email the zip file produced by adb bugreport to [email protected] after filing this issue.

Activity

  1. tonihei commented on Feb 27, 2023

    @tonihei
    Collaborator

    The attached MPD fails to parse because it has id="2-sd-video" in one of the AdaptationSet nodes, which is just not allowed because the value is supposed to be an unsigned integer. Even if I hackily ignore this issue in code, I can't see the problem with getSegmentTimeUs you are describing? It would also help to see a stack trace to know how the problem is triggered.

  2. kamaroyl commented on Mar 6, 2023

    @kamaroyl
    Author

    Ah, apologies, that was an early pass when the packager was putting in the wrong id. I'm able to reproduce by hosting this mpd with a python simple http server and setting the ExoPlayer demo to allow clear text traffic.
    ExoPlayerException.zip

  3. tonihei commented on Mar 7, 2023

    @tonihei
    Collaborator

    Thanks, we'll provide a fix for this.

  4. locked and limited conversation to collaborators on Jun 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions