obs-ffmpeg: Allow srt stream to disconnect after timeout

Fixes #7848
Currently OBS_OUTPUT_INVALID_STREAM is emitted when a wrong password is
used. This commit expands the signal emission to case of timeouts.

Signed-off-by: pkv <pkv@obsproject.com>
This commit is contained in:
pkv
2022-12-03 15:02:03 -08:00
committed by Jim
parent ba27474027
commit ece4d1e90e
+3 -2
View File
@@ -155,9 +155,10 @@ static int libsrt_network_wait_fd(URLContext *h, int eid, int write)
/* Socket reported in wsock AND rsock signifies an error. */
int reason = srt_getrejectreason(*ready);
if (reason == SRT_REJ_BADSECRET || reason == SRT_REJ_UNSECURE) {
if (reason == SRT_REJ_BADSECRET || reason == SRT_REJ_UNSECURE ||
reason == SRT_REJ_TIMEOUT) {
blog(LOG_ERROR,
"[obs-ffmpeg mpegts muxer / libsrt]: Connection rejected, wrong password");
"[obs-ffmpeg mpegts muxer / libsrt]: Connection rejected, wrong password or invalid URL");
return OBS_OUTPUT_INVALID_STREAM;
} else {
blog(LOG_ERROR,