diff options
author | Howard Hinnant <hhinnant@apple.com> | 2012-08-24 22:03:03 +0000 |
---|---|---|
committer | Howard Hinnant <hhinnant@apple.com> | 2012-08-24 22:03:03 +0000 |
commit | dbbdd0c1f05dbdd32aec2e59d3f9874fc53de8db (patch) | |
tree | 67bbae39d9ceedd807327e11047a658300850cff /libcxx/include | |
parent | bad901b36286d7f4db446eedad22a9ca66c5a436 (diff) | |
download | bcm5719-llvm-dbbdd0c1f05dbdd32aec2e59d3f9874fc53de8db.tar.gz bcm5719-llvm-dbbdd0c1f05dbdd32aec2e59d3f9874fc53de8db.zip |
Have basic_istream seekg, putback and unget first clear eofbit. Fixes http://llvm.org/bugs/show_bug.cgi?id=13089.
llvm-svn: 162608
Diffstat (limited to 'libcxx/include')
-rw-r--r-- | libcxx/include/istream | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libcxx/include/istream b/libcxx/include/istream index 7312425eb07..b48f8564156 100644 --- a/libcxx/include/istream +++ b/libcxx/include/istream @@ -1263,6 +1263,7 @@ basic_istream<_CharT, _Traits>::putback(char_type __c) try { #endif // _LIBCPP_NO_EXCEPTIONS + this->clear(this->rdstate() & ~ios_base::eofbit); sentry __sen(*this, true); if (__sen) { @@ -1290,6 +1291,7 @@ basic_istream<_CharT, _Traits>::unget() try { #endif // _LIBCPP_NO_EXCEPTIONS + this->clear(this->rdstate() & ~ios_base::eofbit); sentry __sen(*this, true); if (__sen) { @@ -1368,6 +1370,7 @@ basic_istream<_CharT, _Traits>::seekg(pos_type __pos) try { #endif // _LIBCPP_NO_EXCEPTIONS + this->clear(this->rdstate() & ~ios_base::eofbit); sentry __sen(*this, true); if (__sen) if (this->rdbuf()->pubseekpos(__pos, ios_base::in) == pos_type(-1)) |