set javaOpts=\r
set args=\r
\r
-REM By default, give dx a max heap size of 1 gig. This can be overridden\r
-REM by using a "-JXmx..." option (see below).\r
-set defaultMx=-Xmx1024M\r
+REM By default, give dx a max heap size of 1 gig and a stack size of 1meg.\r
+rem This can be overridden by using "-JXmx..." and "-JXss..." options below.\r
+set defaultXmx=-Xmx1024M\r
+set defaultXss=-Xss1m\r
\r
-REM capture all arguments that are not -J options.\r
+REM Capture all arguments that are not -J options.\r
REM Note that when reading the input arguments with %1, the cmd.exe\r
REM automagically converts --name=value arguments into 2 arguments "--name"\r
REM followed by "value". Dx has been changed to know how to deal with that.\r
if [%1]==[] goto endArgs\r
set a=%~1\r
\r
- if [%defaultMx%]==[] goto notXmx\r
+ if [%defaultXmx%]==[] goto notXmx\r
if %a:~0,5% NEQ -JXmx goto notXmx\r
- set defaultMx=\r
+ set defaultXmx=\r
:notXmx\r
\r
+ if [%defaultXss%]==[] goto notXss\r
+ if %a:~0,5% NEQ -JXss goto notXss\r
+ set defaultXss=\r
+ :notXss\r
+\r
if %a:~0,2% NEQ -J goto notJ\r
set javaOpts=%javaOpts% -%a:~2%\r
shift /1\r
\r
:endArgs\r
\r
-set javaOpts=%javaOpts% %defaultMx%\r
+set javaOpts=%javaOpts% %defaultXmx% %defaultXss%\r
\r
call %java_exe% %javaOpts% -Djava.ext.dirs=%frameworkdir% -jar %jarpath% %params%\r