Leave it to the application to decide on the header. No header at all
is better than having the wrong header as DLNA mandates that a missing
header has to be tolerated while a wrong header is an error.
https://bugzilla.gnome.org/show_bug.cgi?id=676020
Consider a downstream element that may issue seeks in very short
succession (e.g. queue2), depending on the access pattern of
the downstream element (e.g. qtdemux with audio/video chunks
interleaved so that there's always a sizeable gap between the
current chunks for each stream). In this case, queue2 will maintain
two ranges, and even when it serves a chunk from memory, it will
switch ranges and make souphttpsrc seek to the end of the available
data for that range, assuming that that's where we'll want to
continue reading from next.
This may lead to the following seek request pattern:
- source reading position A
- seek to B
- now reading position still A, requested_postion is B
- streaming thread to be restarted to continue from B
- seek to A, before streaming thread had time to do the seek
- do_seek() now sees reading position == seek position and
returns early.
- however, requested position is still B from the earlier
seek request
- streaming thread starts up, sees that a seek to B is pending
and requests data from B from the server, while the GstBaseSrc
segment has of course been updated/reset to position A, which
was the last seek request.
- we will now send data for position B and pretend that's the
data from position A (via the newsegment event, etc.)
- this causes data corruption
Reproducible doing seek-emulated fast-forward/backward on 006648.
Error messages should be translated. URIs and filenames should not
be part of the error message string that's shown to the user.
soup_message->reason_phrase is not translated and not suitable as
error message for users (see libsoup documentation). Also fix up
error codes a bit, as far as possible with the existing codes.
Before they contained the URL before the actual failure. The other
way around makes more sense and we do the same in other elements
like filesrc.
Fixes bug #627289.
Previously seekability way always assumed until the first seek actually
failed. Now we assume that all servers are not seekable unless they provide
a Content-Length header. If a seek fails after that we continue to
assume no seekability. Fixes bug #585576.
When "Content-Type" header is "audio/L16", we need to set the caps on the
outgoing buffers so that downstream elements can have means to detect the
stream type and handle it appropriately. Tested with HTTP stream provided
by pulse-audio's http module (git master).
This allows to set the Referer header among other things by
adding a "extra-headers" property that takes a GstStructure
with field=string pairs.
Fixes bug #581806.