You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by gs...@apache.org on 2007/08/14 18:08:27 UTC
svn commit: r565818 -
/harmony/enhanced/drlvm/trunk/vm/vmcore/src/init/parse_arguments.cpp
Author: gshimansky
Date: Tue Aug 14 09:08:26 2007
New Revision: 565818
URL: http://svn.apache.org/viewvc?view=rev&rev=565818
Log:
Applied patch from HARMONY-4618
[drlvm][jedit] DRLVM doesn't support -ms and -mx options
Modified:
harmony/enhanced/drlvm/trunk/vm/vmcore/src/init/parse_arguments.cpp
Modified: harmony/enhanced/drlvm/trunk/vm/vmcore/src/init/parse_arguments.cpp
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/vmcore/src/init/parse_arguments.cpp?view=diff&rev=565818&r1=565817&r2=565818
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/vmcore/src/init/parse_arguments.cpp (original)
+++ harmony/enhanced/drlvm/trunk/vm/vmcore/src/init/parse_arguments.cpp Tue Aug 14 09:08:26 2007
@@ -264,18 +264,18 @@
} else if (strcmp(option, "-client") == 0 || strcmp(option, "-server") == 0) {
p_env->VmProperties()->set("em.properties", option + 1);
- } else if (begins_with(option, "-Xms")) {
- // cut -Xms
- const char* arg = option + 4;
+ } else if (begins_with(option, "-Xms") || begins_with(option, "-ms")) {
+ // cut -Xms || -ms
+ const char* arg = option + (begins_with(option, "-ms") ? 3 : 4);
TRACE2("init", "gc.ms = " << arg);
if (atoi(arg) == 0) {
LECHO(34, "Negative or invalid heap size. Default value will be used!");
}
p_env->VmProperties()->set("gc.ms", arg);
- } else if (begins_with(option, "-Xmx")) {
+ } else if (begins_with(option, "-Xmx") || begins_with(option, "-mx")) {
// cut -Xmx
- const char* arg = option + 4;
+ const char* arg = option + (begins_with(option, "-mx") ? 3 : 4);
TRACE2("init", "gc.mx = " << arg);
if (atoi(arg) == 0) {
LECHO(34, "Negative or invalid heap size. Default value will be used!");