Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Streaming to local server with SRT in listener mode using "Start streaming" without a connection occurring prevents OBS from closing #10504

Open
robedpixel opened this issue Apr 10, 2024 · 3 comments · May be fixed by #10508
Assignees
Labels
Confirmed This bug report has been confirmed by project members Fix available

Comments

@robedpixel
Copy link

robedpixel commented Apr 10, 2024

Operating System Info

Windows 11

Other OS

No response

OBS Studio Version

Other

OBS Studio Version (Other)

30.1.2

OBS Studio Log URL

https://obsproject.com/logs/AWe6fUonS1skxhOO

OBS Studio Crash Log URL

No response

Expected Behavior

When attempting to stream locally in listener mode using SRT with the "Start Streaming" button, if no client connects to OBS to view the stream. OBS should close properly when exiting.

Current Behavior

When attempting to stream locally in listener mode using SRT with the "Start Streaming" button, if no client connects to OBS to view the stream. OBS seems to close when clicking the exit button, but the process is still running (icon can be seen in the system tray) and not responsive. Closing OBS requires ending the process through task manager

Steps to Reproduce

  1. In settings, set the service to custom and the server to srt://[local ip address]:[port]?mode=listener
  2. Click "Start Streaming" to begin stream
  3. Click "Exit" to exit OBS
  4. OBS seems to exit, but process is still running and icon will still be present in system tray

Anything else we should know?

Please provide an option to cancel the connection when attempting to stream in listener mode using SRT with the streaming function

@pkviet pkviet self-assigned this Apr 10, 2024
@pkviet pkviet added the Confirmed This bug report has been confirmed by project members label Apr 10, 2024
@pkviet
Copy link
Member

pkviet commented Apr 10, 2024

I can confirm the bug.
Thanks for the report.

pkviet added a commit to pkviet/obs-studio that referenced this issue Apr 10, 2024
Fixes obsproject#10504.
When starting an SRT stream in listener mode, if no connection is made
by a client, the socket was not closed when exiting obs.
This fixes the issue so that SRT is closed properly.

Signed-off-by: pkv <[email protected]>
pkviet added a commit to pkviet/obs-studio that referenced this issue Apr 10, 2024
Fixes obsproject#10504.
When starting an SRT stream in listener mode, if no connection is made
by a client, the socket was not closed when exiting obs.
This fixes the issue so that SRT is closed properly.

Signed-off-by: pkv <[email protected]>
@pkviet pkviet linked a pull request Apr 10, 2024 that will close this issue
6 tasks
@pkviet
Copy link
Member

pkviet commented Apr 10, 2024

Fixed with #10508

pkviet added a commit to pkviet/obs-studio that referenced this issue Apr 11, 2024
Fixes obsproject#10504.
When starting an SRT stream in listener mode, if no connection is made
by a client, the socket was not closed when exiting obs.
This fixes the issue so that SRT is closed properly.

Signed-off-by: pkv <[email protected]>
pkviet added a commit to pkviet/obs-studio that referenced this issue Apr 11, 2024
Fixes obsproject#10504.
When starting an SRT stream in listener mode, if no connection is made
by a client, the socket was not closed when exiting OBS.
This fixes the issue so that SRT is closed properly.

Signed-off-by: pkv <[email protected]>
@tt2468
Copy link
Member

tt2468 commented Apr 12, 2024

(Comment accidentally posted here instead of #10508)

pkviet added a commit to pkviet/obs-studio that referenced this issue May 4, 2024
Fixes obsproject#10504.
There was a bug in FFmpeg implementation which was hidden by a bug in
libsrt; it was fixed in a recent commit [1].
When we ported FFmpeg libsrt.c to obs, we brought the said bug along.
When starting an SRT stream in listener mode, if no connection is made
by a client, there were two issues:
- 1) obs was stuck into a connecting loop,
- 2) the socket was not closed when exiting OBS.
This fixes the issue so that SRT is displaying that a stream started
when in listener mode even if NO client is connected.
This is the correct behaviour for a listener.
The stream now closes properly.

[1] https://git.videolan.org/?p=ffmpeg.git;a=commit;h=87677c2195e86b126c3438439a05d0a46ae5bb50
Signed-off-by: pkv <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Confirmed This bug report has been confirmed by project members Fix available
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants