[Live-devel] Bug analyze_sei_data() & Session timeout questions
Ross Finlayson
finlayson at live555.com
Fri Jun 7 01:31:17 PDT 2013
> RtspServer: An OPTIONS with a proper "Session: XYZ" does not seem to trigger RTSPClientSession::noteLiveness().
> Is that a wanted behavior ?
Yes, because the "OPTIONS" command applies to the entire server, and is not specific to a particular session. (In other words, a "Session:" header in an "OPTIONS" command is ignored.)
> If yes, apart from sending RTCP
No, "apart from sending RTCP" should not apply here, because RTCP is a mandatory part of the RTP/RTCP protocol. A RTSP/RTP client should also implement RTCP, and send periodic RTCP "RR" ("Reception Report") packets, which the server will recognize as indicating that the client is still alive. (Note that our RTSP client implementation automatically includes RTCP.)
Having said that, I should note that our server will also recognize any session-specific command (including "GET_PARAMETER") as indicating client liveness.
> would it be possible to change the many
[...]
> to use
>
> "Session: %08X;timeout=%u\r\n\r\n", ..., fOurSessionId, fReclamationTestSeconds);
Of course it would be 'possible', but I'm probably not going to do it, because (1) it's not required, and (2) it is not necessary, if clients send RTCP "RR" reports, as they are supposed to. (I'm disinclined to implement a feature that might encourage RTSP client developers (not using our libraries) to not implement RTCP.)
> Bug:
> In following code, if "if (NumBytesInNALunit > maxSize) return;" occurs, 'nalUnitCopySize' is not set to 0, 'seiSize' is unset/random, and it will most likely crash in the while loop.
> Solution :
> 1: Put 'nalUnitCopySize = 0;' before the return in H264VideoStreamParser::removeEmulationBytes
> 2: unsigned seiSize = 0;
Yes, that's a bug, albeit one that is unlikely to ever get triggered, because no SPS NAL unit should ever be larger than "SPS_MAX_SIZE" (and ditto for SEL NAL units and "SEI_MAX_SIZE"). Nonetheless, your suggested fix will be included in the next release of the software.
Ross Finlayson
Live Networks, Inc.
http://www.live555.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.live555.com/pipermail/live-devel/attachments/20130607/708a6946/attachment.html>
More information about the live-devel
mailing list