libstdc++/3141: DR 243: basic_istream::get and getline when sentry reports failure
bkoz@gcc.gnu.org
bkoz@gcc.gnu.org
Tue Jun 12 14:36:00 GMT 2001
Synopsis: DR 243: basic_istream::get and getline when sentry reports failure
Responsible-Changed-From-To: unassigned->bkoz
Responsible-Changed-By: bkoz
Responsible-Changed-When: Tue Jun 12 14:36:31 2001
Responsible-Changed-Why:
Mine.
State-Changed-From-To: open->feedback
State-Changed-By: bkoz
State-Changed-When: Tue Jun 12 14:36:31 2001
State-Changed-Why:
I've made the char_type() changes.
For the rest, I think your analysis is wrong. The point is that the terminating NULL *is* added unconditionally, and this is clarifying language to support this. Thus, the moving of the adding char_type() to terminate the string inside the if(sentry) loop would cause a defect, not fix one.
There's a reason for the not checking n > 0 for the second bit, I can't remember it offhand but it has to do with changing required error flags. It's checked for in the testsuite, so changing this one small bit will probably show the failure. Anyway.
-benjamin
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view&pr=3141&database=gcc
More information about the Gcc-bugs
mailing list