Author: cazfi
Date: Thu Oct 15 18:58:11 2015
New Revision: 30097

URL: http://svn.gna.org/viewcvs/freeciv?rev=30097&view=rev
Log:
Check unused entries from game.ruleset only after also settings have been 
loaded.

See patch #6407

Modified:
    branches/S2_6/server/ruleset.c

Modified: branches/S2_6/server/ruleset.c
URL: 
http://svn.gna.org/viewcvs/freeciv/branches/S2_6/server/ruleset.c?rev=30097&r1=30096&r2=30097&view=diff
==============================================================================
--- branches/S2_6/server/ruleset.c      (original)
+++ branches/S2_6/server/ruleset.c      Thu Oct 15 18:58:11 2015
@@ -5797,9 +5797,8 @@
     }
   }
 
-  if (ok) {
-    secfile_check_unused(file);
-  }
+  /* secfile_check_unused() is not here, but only after also settings section
+   * has been loaded. */
 
   return ok;
 }
@@ -6908,6 +6907,10 @@
   if (ok) {
     /* Only load settings for a sane ruleset */
     ok = settings_ruleset(gamefile, "settings", act);
+
+    if (ok) {
+      secfile_check_unused(gamefile);
+    }
   }
 
   nullcheck_secfile_destroy(techfile);


_______________________________________________
Freeciv-commits mailing list
Freeciv-commits@gna.org
https://mail.gna.org/listinfo/freeciv-commits

Reply via email to