]> git.mxchange.org Git - flightgear.git/commitdiff
UIUC: fix check_float (EOF is not an error in this context)
authorRebecca N. Palmer <rebecca_palmer@zoho.com>
Fri, 3 Apr 2015 13:18:04 +0000 (14:18 +0100)
committerRebecca N. Palmer <rebecca_palmer@zoho.com>
Fri, 3 Apr 2015 13:18:04 +0000 (14:18 +0100)
http://sourceforge.net/p/flightgear/mailman/message/33683003/

src/FDM/UIUCModel/uiuc_menu_functions.cpp

index 5d520ca78ce4e875495b7d0d3164269d7bb8ed7c..a1160495a72df27b9e2c86e2ae6093d5d9042976 100644 (file)
@@ -72,7 +72,7 @@ bool check_float( const string &token)
 {
   float value;
   istringstream stream(token.c_str()); 
-  return (stream >> value).good();
+  return !((stream >> value).fail());
 }
 
 void d_2_to_3( double array2D[100][100], double array3D[][100][100], int index3D)