From 6787bf85ff50a6c7832bb122068118f041c8335f Mon Sep 17 00:00:00 2001 From: Sam Lidder Date: Sat, 18 Aug 2012 01:39:59 -0400 Subject: [PATCH] fix infinite loop bug when reading test cases - pushing character back onto stream causes stream state to never fail when test cases contain string and/or vector for paramater/return values - simplest case found so far: parameter: string, return: string --- src/com/dogcows/resources/C++Driver | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/com/dogcows/resources/C++Driver b/src/com/dogcows/resources/C++Driver index 9ca8579..60ef873 100644 --- a/src/com/dogcows/resources/C++Driver +++ b/src/com/dogcows/resources/C++Driver @@ -67,10 +67,6 @@ std::istream& operator >> (std::istream& in, std::string& str) } str = s.str(); } - else - { - in.putback(c); - } return in; } @@ -94,10 +90,6 @@ std::istream& operator >> (std::istream& in, std::vector& vec) while (in.good() && std::isspace(in.peek())) in.get(); } } - else - { - in.putback(c); - } return in; } -- 2.45.2