diff options
Diffstat (limited to 'erts/etc/common/erlexec.c')
-rw-r--r-- | erts/etc/common/erlexec.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/erts/etc/common/erlexec.c b/erts/etc/common/erlexec.c index b29190e4d9..f11ec2320a 100644 --- a/erts/etc/common/erlexec.c +++ b/erts/etc/common/erlexec.c @@ -141,6 +141,8 @@ static char *pluss_val_switches[] = { "wt", "ws", "ss", + "ssdcpu", + "ssdio", "pp", "ub", NULL @@ -585,8 +587,12 @@ int main(int argc, char **argv) erts_snprintf(tmpStr, sizeof(tmpStr), "%s" DIRSEP "%s" BINARY_EXT, bindir, emu); emu = strsave(tmpStr); - add_Eargs(emu); /* Will be argv[0] -- necessary! */ - + s = get_env("ESCRIPT_NAME"); + if(s) { + add_Eargs(s); /* argv[0] = scriptname*/ + } else { + add_Eargs(progname); /* argv[0] = erl or cerl */ + } /* * Add the bindir to the path (unless it is there already). */ |