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

Unhandled EWOULDBLOCK errors breaking TlsStream #64

Closed
osa1 opened this issue Dec 23, 2017 · 5 comments
Closed

Unhandled EWOULDBLOCK errors breaking TlsStream #64

osa1 opened this issue Dec 23, 2017 · 5 comments

Comments

@osa1
Copy link
Owner

osa1 commented Dec 23, 2017

Originally reported by @reading123 on #61,

It seems like some EWOULDBLOCK errors are slipping through our error handlers and causing Conn methods to fail. The error message tiny prints is:

Connection error: The underlying stream reported an error (operation would block)

I can't reproduce this so I'm not sure how to solve. As a starting point we should probably compare our EWOULDBLOCK handling with tokio-core's TcpStream https://github.com/tokio-rs/tokio-core/blob/master/src/net/tcp.rs .

I also created the issue sfackler/rust-native-tls#63 but later it occured to me that if we do EWOULDBLOCK in stream::tcp::TcpStream we may not need any support from native_tls.

@osa1
Copy link
Owner Author

osa1 commented Dec 24, 2017

I can reproduce this reliably (as in, it never works) when I compile tiny with statically linked openssl-1.1.0g.

@osa1
Copy link
Owner Author

osa1 commented Dec 24, 2017

@reading123 could you try again with latest tiny? (cargo install --force --git https://github.com/osa1/tiny) If you're getting The OpenSSL library reported an error that's a certificate verification error, I'm not sure how to solve it yet. For some reason it works when I use OpenSSL from my distro's package manager.

@reading123
Copy link

Yay it works!! No errors here.

@reading123
Copy link

Also, Merry Christmas! :)

@osa1
Copy link
Owner Author

osa1 commented Dec 25, 2017

Good to hear. Merry Christmas to you too :)

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

No branches or pull requests

2 participants