]> git.mxchange.org Git - flightgear.git/commitdiff
Patch from Norman to do the code/base version comparison check a little
authorcurt <curt>
Fri, 7 Jun 2002 23:26:07 +0000 (23:26 +0000)
committercurt <curt>
Fri, 7 Jun 2002 23:26:07 +0000 (23:26 +0000)
more sensibly (and print the correct error message.)

src/Main/main.cxx

index 68c1237b4502de8d4289edc50e525836049cbd9f..4c0a44d6cb85301d4b52a70ca9a21246c3864185 100644 (file)
@@ -1419,15 +1419,17 @@ int mainLoop( int argc, char **argv ) {
     fgInitFGRoot(argc, argv);
 
     // Check for the correct base package version
+    static char required_version[] = "0.7.11pre1";
     string base_version = fgBasePackageVersion();
-    if ( !(base_version == "0.7.11pre1") ) {
+    if ( !(base_version == required_version) ) {
         // tell the operator how to use this application
         fgUsage();
 
        SG_LOG( SG_GENERAL, SG_ALERT, "Base package check failed ... "
                << "Found version " << base_version << " at: "
                 << globals->get_fg_root() );
-        SG_LOG( SG_GENERAL, SG_ALERT, "Please upgrade to version 0.7.9" );
+        SG_LOG( SG_GENERAL, SG_ALERT, "Please upgrade to version"
+                << required_version);
        exit(-1);
     }