mirror of
https://github.com/moonlight-stream/moonlight-common-c.git
synced 2026-06-17 22:31:21 +00:00
Fixes RTSP session id parsing issue. (#39)
* Fixes RTSP session id parsing issue. * Pull Request #39 changes requested.
This commit is contained in:
committed by
Cameron Gutman
parent
80eba25bb9
commit
0006beb32b
@@ -579,12 +579,20 @@ int performRtspHandshake(void) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
sessionId = getOptionContent(response.options, "Session");
|
sessionId = getOptionContent(response.options, "Session");
|
||||||
|
|
||||||
if (sessionId == NULL) {
|
if (sessionId == NULL) {
|
||||||
Limelog("RTSP SETUP streamid=audio is missing session attribute");
|
Limelog("RTSP SETUP streamid=audio is missing session attribute");
|
||||||
ret = -1;
|
ret = -1;
|
||||||
goto Exit;
|
goto Exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Given there is a non-null session id, get the
|
||||||
|
// first token of the session until ";", which
|
||||||
|
// resolves any 454 session not found errors on
|
||||||
|
// standard RTSP server implementations.
|
||||||
|
// (i.e - sessionId = "DEADBEEFCAFE;timeout = 90")
|
||||||
|
sessionId = strtok(sessionId, ";");
|
||||||
|
|
||||||
strcpy(sessionIdString, sessionId);
|
strcpy(sessionIdString, sessionId);
|
||||||
hasSessionId = 1;
|
hasSessionId = 1;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user