[Bug 751735] dashdemux: incorrect parsing and handling of segment templates
GStreamer (GNOME Bugzilla)
bugzilla at gnome.org
Mon Jul 6 00:26:23 PDT 2015
https://bugzilla.gnome.org/show_bug.cgi?id=751735
Sebastian Dröge (slomo) <slomo at coaxion.net> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |slomo at coaxion.net
--- Comment #3 from Sebastian Dröge (slomo) <slomo at coaxion.net> ---
(In reply to Thiago Sousa Santos from comment #2)
> I'm not sure about this one, I think your interpretation is correct because
> the spec tells to replace the $Number$ with the value and then the 2nd
> $Number$ would lose its first $ and would not be replaced, but what if we
> start replacing from the end towards the start or if all replacements should
> be done 'at the same time'? What interpretation could have us covering most
> of the valid use cases?
I would make it left to right, and if stuff is not consistent make it an error
or just fail with the resulting 404. As the spec uses $ as the opening and
closing "parenthesis", it's not unambiguous and there can't be a solution that
catches everything.
> > {"TestMedia$Time", NULL}, /* Identifier not finished with $ */
> > {"Time$Time%0d$", "Time100"}, /* usage of format smaller than number
> > of digits */
> > {"Time$Time%01d$", "Time100"}, /* usage of format smaller than number
> > of digits */
> > {"Time$Time%05d$", "Time00100"}, /* usage of format bigger than number of
> > digits */
>
> > {"Time$Time%05dtest$", "Time00100test"}, /* usage extra text in format */
>
> Is this valid? I couldn't find anything in the spec that allowed suffixing
> that was not the %0d identifier.
IIRC it's valid, but even if not I wouldn't surprise if streams with that
appear out there. It seems too intuitive that this should be possible.
I don't think it's great that C format strings were used here because of that
reason.
> > {"Time$Time%05u$", "Time00100"}, /* %u format */
> > {"Time$Time%05x$", "Time00064"}, /* %x format */
> > {"Time$Time%05utest$", "Time00100test"}, /* %u format followed by text */
> > {"Time$Time%05xtest$", "Time00064test"}, /* %x format followed by text */
> Are %u and %x allowed by the spec? It seems that it should always be a %d
> but as it is a bit dubious I'd be ok for accepting those as well.
The spec only allows %d, yes. But because it's a bit dubious as you say, we
also support %x and %u. In mpd parser.
--
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