Only one of the demuxer actually set the flag (at all), live555. That
is also the only demuxer that supports rate control, so infer the value
accordingly.
This keystore is used to store credentials on memory if no others keystore is
found or if the user doesn't want to store them permanently. This keystore is
owned by libvlc and is shared with all vlc objects. It's released when the
libvlc instance is released.
I wrote a hackish script to locate instances where new can throw
but where the original author has assumed that it will return
nullptr when there is a memory allocation problem.
In short, cases such as `ptr = new T; if (ptr) ...` has now
been changed to `ptr = new (std::nothrow) T; if (ptr) ...`.
Since a throwing `new` will always yield a non-nullptr pointer,
code that follows similar patterns to the previous example are
therefor redundant.
Example (from modules/access/dshow/filter.cpp):
*ppEnum = new CaptureEnumMediaTypes( p_input, p_pin, this );
if( *ppEnum == NULL )
return E_OUTOFMEMORY; // unreachable, new will never return NULL
Fixed:
*ppEnum = new (std::nothrow) CaptureEnumMediaTypes( p_input, p_pin, this );
if( *ppEnum == NULL )
return E_OUTOFMEMORY;
Signed-off-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
That parameter assumed that the query was part of the path. However it
is not, which leads to invalid host name, and eventually failure when
the path is missing. In practice, passing any value other than '?' as
separator would not work properly.
Remaining vlc_UrlParse() call sites without the option separator do not
support query at the protocol level anyway, so they are unaffected by the
change.
Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
Fixes ticket#14939
Because Demux() is not called during PAUSE the GET_PARAMETER keepalives are
sent by the TimeoutPrevention thread. However this was not giving Live555
a chance to handle the responses through doEventLoop(), and so the responses
were queued up. Because of a separate issue in handling pipelined
GET_PARAMETER responses in Live555 itself (now fixed, 2015-06-24), after two
GPs this would result in the loss of the PLAY response on resume, locking
everything up.
Even with the fix to Live555, queuing up all GP responses until the stream
is resumed is unpleasant and will eventually overflow Live555's response
buffer.
This fix calls the usual Live555 response handling mechanism for GPs sent
in the background thread during pause. I have not added it to the normal
GP sends in Demux() because that calls doEventLoop() anyway, and to do so
would add a delay to normal processing.
TimeoutPrevention now requires access to p_demux itself, not just p_sys.
A mutex has been added to protect LIVE555 from simultaneous calls within
Demux() or Control() and the TimeoutPrevention() thread
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
So far no keep-alive messages are sent when GET_PARAMETERS is not supported by
the server. Change this to fall back to sending OPTIONS as keep-alive message,
which is the default keep-alive message in the SAT>IP specification. As
RFC2326 does not enforce a specific command as keep-alive message this shall
be valid for any compliant RTSP server.
Signed-off-by: Julian Scheel <julian@jusst.de>
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
Register a satip-access, which uses a hardcoded default SDP dataset instead of
querying it via DESCRIBE. While some SAT>IP servers implement a common
DESCRIBE the spec is allowing servers to only support DESCRIBE of already
configured sessions, which requires SETUP to be executed before DESCRIBE can
be used at all.
Signed-off-by: Julian Scheel <julian@jusst.de>
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
This might suppress some warnings (and very slightly reduce code size)
when assertions are disabled. Not that I particularly like to create
VLC-specific macros.
If the input is dead, the source stream (demux_t.s) return an
error. There is no point checking that the demux is dead separately. In
fact, there is even a race where the stream will be dead but the demux
will not.
If no header is given, deduce it from the decoder format.
Tested for mono, stereo and with/without --codec avcodec at
8000, 12000, 16000, 24000 and 48000hz.
First for the "a=lang:" session attribute, then for each subsession
look for the same attribute, and use the session attribute if none
was found.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>