Fix #4037 SRS should not send the publish start message onStatus(NetStream.Publish.Start) if hooks fail, which causes OBS to repeatedly reconnect.
Note that this fix does not send an RTMP error message when publishing fails, because neither OBS nor FFmpeg process this specific error message; they only display a general error.
Apart from the order of messages, nothing else has been changed. Previously, we sent the publish start message onStatus(NetStream.Publish.Start) before the HTTP hook on_publish; now, we have modified it to send this message after the HTTP hook.
Fix #4037 SRS should not send the publish start message
onStatus(NetStream.Publish.Start)
if hooks fail, which causes OBS to repeatedly reconnect.Note that this fix does not send an RTMP error message when publishing fails, because neither OBS nor FFmpeg process this specific error message; they only display a general error.
Apart from the order of messages, nothing else has been changed. Previously, we sent the publish start message
onStatus(NetStream.Publish.Start)
before the HTTP hookon_publish
; now, we have modified it to send this message after the HTTP hook.