From 068f7aa9d9acdcf58a208c712b84a8bafbf94d46 Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Wed, 28 Apr 2021 17:06:04 -0500 Subject: [PATCH] Allow connection interruption during the RTSP handshake --- src/RtspConnection.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/RtspConnection.c b/src/RtspConnection.c index 07efce1..ebf1597 100644 --- a/src/RtspConnection.c +++ b/src/RtspConnection.c @@ -298,6 +298,11 @@ Exit: } static bool transactRtspMessage(PRTSP_MESSAGE request, PRTSP_MESSAGE response, bool expectingPayload, int* error) { + if (ConnectionInterrupted) { + *error = -1; + return false; + } + if (useEnet) { return transactRtspMessageEnet(request, response, expectingPayload, error); }