-
Notifications
You must be signed in to change notification settings - Fork 1k
fix: throw exception on stream_socket_enable_crypto() warning #1158
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
Conversation
2e18096
to
64f776c
Compare
@egorgrushko please review this fix |
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #1158 +/- ##
============================================
+ Coverage 74.10% 74.58% +0.47%
- Complexity 1042 1044 +2
============================================
Files 39 39
Lines 3136 3144 +8
============================================
+ Hits 2324 2345 +21
+ Misses 812 799 -13 ☔ View full report in Codecov by Sentry. |
@ramunasd I'm concerned about usleep. |
64f776c
to
e344ed4
Compare
@egorgrushko I added instant return if enable is successful on first attempt and lower delay, just 1ms. In the future all connections will be lazy, so this won't affect applications so much. |
I will release this as patch version 3.6.1 on Monday. |
@ramunasd thank you! |
This fixes 2 issues introduced in version 3.6.0:
stream_socket_enable_crypto()
are ignored and it's not good, because they provide valueable info about wrong SSL options or peer validation issues. Any consequent call to that method makes no sense since handshake is failed and connection is not useable at all.