From: Vincent van Ravesteijn Date: Wed, 2 May 2012 11:37:32 +0000 (+0200) Subject: MathParser: Do not rewind the stream if we can't read from it X-Git-Tag: 2.1.0beta1~1919 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=1ef930c05826340d7497d6994338f6d63772de5f;p=features.git MathParser: Do not rewind the stream if we can't read from it If the stream is not good, we don't need to 'putback', because we didn't read anything yet. If we now do rewind the stream, we are asking for problems as in bug #8089. This was introduced in [3cafb856\lyxgit] to fix bug #4318. --- diff --git a/src/mathed/MathParser.cpp b/src/mathed/MathParser.cpp index b3f1bca76b..ad804e1f84 100644 --- a/src/mathed/MathParser.cpp +++ b/src/mathed/MathParser.cpp @@ -536,7 +536,6 @@ char_type Parser::getChar() { if (!good()) { error("The input stream is not well..."); - putback(); return 0; } return tokens_[pos_++].character();