do not miss original exception in std::iostreams#96455
Merged
Conversation
Contributor
|
Workflow [PR], commit [4fd256a] Summary: ❌
|
Member
|
This is golden! Thanks, @Diskein! |
serxa
approved these changes
Feb 9, 2026
Member
|
Are you okay if I backport this fix? |
robot-clickhouse-ci-2
added a commit
that referenced
this pull request
Mar 23, 2026
Cherry pick #96455 to 25.12: do not miss original exception in std::iostreams
robot-clickhouse
added a commit
that referenced
this pull request
Mar 23, 2026
This was referenced Mar 23, 2026
robot-clickhouse-ci-2
added a commit
that referenced
this pull request
Mar 23, 2026
Cherry pick #96455 to 26.1: do not miss original exception in std::iostreams
robot-clickhouse
added a commit
that referenced
this pull request
Mar 23, 2026
clickhouse-gh bot
added a commit
that referenced
this pull request
Mar 23, 2026
Backport #96455 to 26.1: do not miss original exception in std::iostreams
CheSema
added a commit
that referenced
this pull request
Mar 24, 2026
Backport #96455 to 25.12: do not miss original exception in std::iostreams
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We have tons of classes in
POCOwhich use multiple inheritance like thisclass Net_API HTTPChunkedOutputStream : public HTTPChunkedIOS, public std::ostreamclass Net_API HTTPChunkedInputStream : public HTTPChunkedIOS, public std::istreamHere
HTTPChunkedIOSandHTTPChunkedIOSdopoco_ios_init(&_buf);in its c-tors. which isthe main thing here is
this->exceptions(std::ios::failbit | std::ios::badbit);BUT the second parent
std::ostream/std::istreamdoes onlythis->init(__sb);and by this it rewrites__exceptions_ = goodbit;So all the efforts with
poco_ios_initwas in vain. Thanks @Diskein, he quickly noticed that override.Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
set
this->exceptions(std::ios::badbit);for the std's streams inside Poco.Documentation entry for user-facing changes