-
-
Notifications
You must be signed in to change notification settings - Fork 913
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
tcp: fix tcp_socket_dead() for FreeBSD #1112
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The FreeBSD port of tvheadend couldn't stream Live TV, and debug log shows webui judged the peer socket closed immediately after starting streaming: 2018-04-15 06:30:04.996 [ DEBUG]:webui: Start streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974 2018-04-15 06:30:04.996 [ DEBUG]:webui: Stop streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974, client hung up It looks because tcp_socket_dead() misunderstood the zero-return from recv(). For the FreeBSD, recv() might return zero for alive sockets which have nothing to read. Patch tested with the latest FreeBSD port of tvheadend-4.2.6.
uqs
pushed a commit
to freebsd/freebsd-ports
that referenced
this pull request
Apr 18, 2018
The FreeBSD port of tvheadend couldn't stream Live TV, and debug log shows webui judged the peer socket closed immediately after starting streaming: 2018-04-15 06:30:04.996 [ DEBUG]:webui: Start streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974 2018-04-15 06:30:04.996 [ DEBUG]:webui: Stop streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974, client hung up It looks tcp_socket_dead() misunderstood the zero-return from recv(). For the FreeBSD, recv() might return zero for alive sockets which have nothing to read. Submitted by: Jongsung Kim <jongsung.kim@gmail.com> Obtained from: tvheadend/tvheadend#1112 git-svn-id: svn+ssh://svn.freebsd.org/ports/head@467705 35697150-7ecd-e111-bb59-0022644237b5
uqs
pushed a commit
to freebsd/freebsd-ports
that referenced
this pull request
Apr 18, 2018
The FreeBSD port of tvheadend couldn't stream Live TV, and debug log shows webui judged the peer socket closed immediately after starting streaming: 2018-04-15 06:30:04.996 [ DEBUG]:webui: Start streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974 2018-04-15 06:30:04.996 [ DEBUG]:webui: Stop streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974, client hung up It looks tcp_socket_dead() misunderstood the zero-return from recv(). For the FreeBSD, recv() might return zero for alive sockets which have nothing to read. Submitted by: Jongsung Kim <jongsung.kim@gmail.com> Obtained from: tvheadend/tvheadend#1112
swills
pushed a commit
to swills/freebsd-ports
that referenced
this pull request
Apr 18, 2018
The FreeBSD port of tvheadend couldn't stream Live TV, and debug log shows webui judged the peer socket closed immediately after starting streaming: 2018-04-15 06:30:04.996 [ DEBUG]:webui: Start streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974 2018-04-15 06:30:04.996 [ DEBUG]:webui: Stop streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974, client hung up It looks tcp_socket_dead() misunderstood the zero-return from recv(). For the FreeBSD, recv() might return zero for alive sockets which have nothing to read. Submitted by: Jongsung Kim <jongsung.kim@gmail.com> Obtained from: tvheadend/tvheadend#1112 git-svn-id: svn+ssh://svn.freebsd.org/ports/head@467705 35697150-7ecd-e111-bb59-0022644237b5
Jehops
pushed a commit
to Jehops/freebsd-ports-legacy
that referenced
this pull request
Apr 18, 2018
The FreeBSD port of tvheadend couldn't stream Live TV, and debug log shows webui judged the peer socket closed immediately after starting streaming: 2018-04-15 06:30:04.996 [ DEBUG]:webui: Start streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974 2018-04-15 06:30:04.996 [ DEBUG]:webui: Stop streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974, client hung up It looks tcp_socket_dead() misunderstood the zero-return from recv(). For the FreeBSD, recv() might return zero for alive sockets which have nothing to read. Submitted by: Jongsung Kim <jongsung.kim@gmail.com> Obtained from: tvheadend/tvheadend#1112 git-svn-id: svn+ssh://svn.freebsd.org/ports/head@467705 35697150-7ecd-e111-bb59-0022644237b5
Merged. Thanks. |
svmhdvn
pushed a commit
to svmhdvn/freebsd-ports
that referenced
this pull request
Jan 10, 2024
The FreeBSD port of tvheadend couldn't stream Live TV, and debug log shows webui judged the peer socket closed immediately after starting streaming: 2018-04-15 06:30:04.996 [ DEBUG]:webui: Start streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974 2018-04-15 06:30:04.996 [ DEBUG]:webui: Stop streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974, client hung up It looks tcp_socket_dead() misunderstood the zero-return from recv(). For the FreeBSD, recv() might return zero for alive sockets which have nothing to read. Submitted by: Jongsung Kim <jongsung.kim@gmail.com> Obtained from: tvheadend/tvheadend#1112
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The FreeBSD port of tvheadend couldn't stream Live TV, and debug
log shows webui judged the peer socket closed immediately after
starting streaming:
2018-04-15 06:30:04.996 [ DEBUG]:webui: Start streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974
2018-04-15 06:30:04.996 [ DEBUG]:webui: Stop streaming /stream/mux/c4bc67bdaa13457e33740ca883cc4d75?ticket=7D1B56AD0E434C5F7EBFA4677A7FBE4C94097974, client hung up
It looks because tcp_socket_dead() misunderstood the zero-return
from recv(). For the FreeBSD, recv() might return zero for alive
sockets which have nothing to read.
Patch tested with the latest FreeBSD port of tvheadend-4.2.6.