This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/29026] New: std::basic_istream<>::sentry() fails to catch when reading whitespace
- From: "jimrees at itasoftware dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 11 Sep 2006 21:03:08 -0000
- Subject: [Bug libstdc++/29026] New: std::basic_istream<>::sentry() fails to catch when reading whitespace
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
27.6.1.1 P4 says that formatted input functions should set badbit if a call to
fetch characters from the streambuf throws an exception.
The implementation of this in bits/istream.tcc is done after the sentry is
constructed. But the sentry's constructor may try to read whitespace, and it
is not doing any exception handling, so ios_base::badbit is not getting set in
this case.
--
Summary: std::basic_istream<>::sentry() fails to catch when
reading whitespace
Product: gcc
Version: 4.1.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: jimrees at itasoftware dot com
GCC build triplet: x86_64-redhat-linux
GCC host triplet: x86_64-redhat-linux
GCC target triplet: x86_64-redhat-linux
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29026