Skip to content

Commit

Permalink
libobs: Do not allow reconnect if stop code is OBS_OUTPUT_INVALID_STREAM
Browse files Browse the repository at this point in the history
  • Loading branch information
dsaedtler authored and RytoEX committed Sep 26, 2024
1 parent 32cfa16 commit a0edc5e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions libobs/obs-output.c
Original file line number Diff line number Diff line change
Expand Up @@ -3095,8 +3095,9 @@ static inline bool can_reconnect(const obs_output_t *output, int code)
{
bool reconnect_active = output->reconnect_retry_max != 0;

return (reconnecting(output) && code != OBS_OUTPUT_SUCCESS) ||
(reconnect_active && code == OBS_OUTPUT_DISCONNECTED);
return code != OBS_OUTPUT_INVALID_STREAM &&
((reconnecting(output) && code != OBS_OUTPUT_SUCCESS) ||
(reconnect_active && code == OBS_OUTPUT_DISCONNECTED));
}

void obs_output_signal_stop(obs_output_t *output, int code)
Expand Down

0 comments on commit a0edc5e

Please sign in to comment.