Skip to content

Fix and enhance documentation of TcpListener::accept()#546

Closed
JanZerebecki wants to merge 1 commit intotokio-rs:masterfrom
JanZerebecki:fixdoc-tcplistener-accept
Closed

Fix and enhance documentation of TcpListener::accept()#546
JanZerebecki wants to merge 1 commit intotokio-rs:masterfrom
JanZerebecki:fixdoc-tcplistener-accept

Conversation

@JanZerebecki
Copy link
Contributor

No description provided.

@carllerche
Copy link
Member

Thanks for the PR. The docs are definitely out of date.

I would suggest instead of Err(would_block()), maybe Err(e) where e is an io::Error of kind WouldBlock?

Also, I would suggest removing this May block if there is nothing ready to be accepted. as it isn't true (since the socket is in non-blocking mode).

@JanZerebecki JanZerebecki force-pushed the fixdoc-tcplistener-accept branch from a2b0436 to 9d5d3be Compare February 21, 2017 14:33
@JanZerebecki
Copy link
Contributor Author

Right, I looked at the wrong place for the call making it non-blocking. I adopted your suggestions and clarified a bit more.

@carllerche
Copy link
Member

Thanks, merged: 9792b74

@carllerche carllerche closed this Mar 7, 2017
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

Successfully merging this pull request may close these issues.

2 participants