-
Notifications
You must be signed in to change notification settings - Fork 118
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
Hang forever when reset boost::iostreams::filtering_ostream with a broken sink device #140
Comments
But that is exactly the purpose of the non_blocking_adapter? |
According to https://www.boost.org/doc/libs/1_76_0/libs/iostreams/doc/functions/write.html , To detect whether the failure is permanent, do you think it should also check the fail/bad bit? |
It's a bit hard to say without knowing why the sink device would become "broken" and how it is designed to report that. |
Looking at this again, https://www.boost.org/doc/libs/1_76_0/libs/iostreams/doc/guide/exceptions.html suggests that exceptions should be used to report errors. |
boost version: 1.78
compiler: gcc version 11.2.0
typical stack trace:
At
boost/iostreams/detail/adapter/non_blocking_adapter.hpp:43
I found theiostreams::write
keeps return zero (due to the broken sink device), and it makes the loop starting at line 41 running forever.The text was updated successfully, but these errors were encountered: