Allow additional custom JVM arguments to be specified in an external file.

This commit is contained in:
Michael Bayne
2004-08-09 22:01:56 +00:00
parent 9aa68b81d2
commit 898fcff302
@@ -1,5 +1,5 @@
//
// $Id: Application.java,v 1.28 2004/08/03 03:29:58 mdb Exp $
// $Id: Application.java,v 1.29 2004/08/09 22:01:56 mdb Exp $
package com.threerings.getdown.data;
@@ -274,6 +274,20 @@ public class Application
}
}
// look for custom arguments
File file = getLocalPath("extra.txt");
if (file.exists()) {
try {
List args = ConfigUtil.parsePairs(file, false);
for (Iterator iter = args.iterator(); iter.hasNext(); ) {
String[] pair = (String[])iter.next();
_jvmargs.add(pair[0] + "=" + pair[1]);
}
} catch (Throwable t) {
Log.warning("Failed to parse '" + file + "': " + t);
}
}
// parse and return our application config
UpdateInterface ui = new UpdateInterface();
_name = ui.name = (String)cdata.get("ui.name");