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

server socket does not get EOF when closing client socket without sending any data #92

Open
nojb opened this issue May 9, 2016 · 2 comments

Comments

@nojb
Copy link

nojb commented May 9, 2016

Hello,

As in the subject, there seems to be a bug in libutp: if a connection is opened between a client and a server and the client closes the connection without sending any data, then the server does not get a STATE_EOF state change notification so the socket is kept around forever.

To reproduce, is enough to use ucat on the server as follows:

ucat -d -l -p 5678

and on the client as follows:

ucat -d 127.0.0.1 5678

and close (CTRL-D) the client connection without sending any data. The client will fail with ETIMEDOUT and the server will not get the STATE_EOF notification.

@anacrolix
Copy link
Contributor

I think I had to work around something like this, @nojb does it look related? https://github.com/anacrolix/go-libutp/blob/master/callbacks.go#L75. If so I can test the PR and see if it fixes this problem.

@anacrolix
Copy link
Contributor

I just tried it out and it didn't fix the issue I had.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants