Skip to content

Commit

Permalink
IsNullOrDisposed
Browse files Browse the repository at this point in the history
  • Loading branch information
juliusfriedman committed Nov 21, 2023
1 parent 4bfaf39 commit c63ea5e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion RtspServer/ClientSession.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ The above copyright notice and this permission notice shall be included in all c
using Media.Rtcp;
using Media.Rtsp.Server.MediaTypes;
using System.Threading;
using Media.Common.Extensions.Socket;

namespace Media.Rtsp//.Server
{
Expand Down Expand Up @@ -469,7 +470,7 @@ public void SendRtspData(byte[] data, int offset, int length, SocketFlags flags
if (ex is SocketException se) m_Server.HandleClientSocketException(se, this);

//if not disposed mark disconnected
IsDisconnected = m_RtspSocket is null || IsDisposed || HasRuningServer is false;
IsDisconnected = m_RtspSocket.IsNullOrDisposed() || IsDisposed || HasRuningServer is false;
}
}
}
Expand Down

0 comments on commit c63ea5e

Please sign in to comment.