From: Erik V. <ev...@us...> - 2010-01-22 21:44:46
|
Update of /cvsroot/rails/18xx/rails/util In directory sfp-cvsdas-1.v30.ch3.sourceforge.com:/tmp/cvs-serv18138/rails/util Modified Files: Tag.java Log Message: Safety check on assigning game option value Index: Tag.java =================================================================== RCS file: /cvsroot/rails/18xx/rails/util/Tag.java,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** Tag.java 15 Jan 2010 19:52:01 -0000 1.13 --- Tag.java 22 Jan 2010 21:44:34 -0000 1.14 *************** *** 304,309 **** if (optionValue == null) { // Take the default value ! optionValue = ! GameOption.getByName(name).getDefaultValue(); log.warn("GameOption " + name + "=" + value + " but no assigned value found, assumed "+optionValue); --- 304,309 ---- if (optionValue == null) { // Take the default value ! GameOption go = GameOption.getByName(name); ! optionValue = go != null ? go.getDefaultValue() : ""; log.warn("GameOption " + name + "=" + value + " but no assigned value found, assumed "+optionValue); |