Skip to content

Commit

Permalink
Rebase fixes.
Browse files Browse the repository at this point in the history
  • Loading branch information
juliusfriedman committed Nov 21, 2023
1 parent 9816583 commit b6cbe66
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 10 deletions.
4 changes: 1 addition & 3 deletions Rtsp/RtspClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6607,9 +6607,7 @@ public void EnsureMediaFlows()
{
//Ensure still in playing
if (Common.IDisposedExtensions.IsNullOrDisposed(context) is false &&
m_Playing.ContainsKeys(context.MediaDescription) is false || context.HasAnyRecentActivity) continue;

int requestCseq;
m_Playing.ContainsKey(context.MediaDescription) is false || context.HasAnyRecentActivity) continue;

//Send a pause request if not already paused and the server supports PAUSE and there has been any activity on the context
if (supportPause)
Expand Down
9 changes: 2 additions & 7 deletions RtspServer/ClientSession.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2160,16 +2160,11 @@ the server MUST NOT include a CSeq in the response.
response.CSeq = request.CSeq;
}
//Request is null, check the statusCode, if not BadRequest check for a LastRequest and use that CSeq.
else if (statusCode is not RtspStatusCode.BadRequest &&
Common.IDisposedExtensions.IsNullOrDisposed(LastRequest) is false &&
else if (statusCode is not RtspStatusCode.BadRequest &&
Common.IDisposedExtensions.IsNullOrDisposed(LastRequest) is false &&
LastRequest.CSeq >= 0)
response.CSeq = LastRequest.CSeq;

if (false.Equals(statusCode == RtspStatusCode.BadRequest)) response.CSeq = request.CSeq;
}//Request is null, check the statusCode, if not BadRequest check for a LastRequest and use that CSeq.
else if (false.Equals(statusCode == RtspStatusCode.BadRequest) &&
Common.IDisposedExtensions.IsNullOrDisposed(LastRequest) is false &&
LastRequest.CSeq >= 0) response.CSeq = LastRequest.CSeq;
//Otherwise no CSeq is provided in response...

//Include any reason phrase.
Expand Down
1 change: 1 addition & 0 deletions RtspServer/RtspServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ The above copyright notice and this permission notice shall be included in all c
using Media.Rtsp.Server.Loggers;
using System.Collections.Concurrent;
using System.Threading.Tasks;
using Media.Common.Extensions.Socket;

namespace Media.Rtsp
{
Expand Down

0 comments on commit b6cbe66

Please sign in to comment.