diff options
| author | ptitSeb <sebastien.chev@gmail.com> | 2024-10-10 08:37:59 +0200 |
|---|---|---|
| committer | ptitSeb <sebastien.chev@gmail.com> | 2024-10-10 08:37:59 +0200 |
| commit | 21b5f90a33f8e38ecdd3ca9dc3b167a7b8fba30c (patch) | |
| tree | fca8a56049d6b4d235fda8649f447ab9094b2666 /src/steam.c | |
| parent | d1c5cd7b0a6f7dc52f06627fd161416f0ece0c3c (diff) | |
| download | box64-21b5f90a33f8e38ecdd3ca9dc3b167a7b8fba30c.tar.gz box64-21b5f90a33f8e38ecdd3ca9dc3b167a7b8fba30c.zip | |
Small changed to command line argument handling
Diffstat (limited to 'src/steam.c')
| -rw-r--r-- | src/steam.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/steam.c b/src/steam.c index 8859ce05..c32de63b 100644 --- a/src/steam.c +++ b/src/steam.c @@ -137,10 +137,11 @@ void pressure_vessel(int argc, const char** argv, int nextarg, const char* prog) my_context = NewBox64Context(argc - nextarg); int x86 = my_context->box86path?FileIsX86ELF(argv[nextarg]):0; int x64 = my_context->box64path?FileIsX64ELF(argv[nextarg]):0; + int sh = my_context->bashpath?FileIsShell(argv[nextarg]):0; // create the new argv array const char** newargv = (const char**)box_calloc((argc-nextarg)+1+((x86 || x64)?1:0), sizeof(char*)); - if(x86 || x64) { - newargv[0] = x64?my_context->box64path:my_context->box86path; + if(x86 || x64 || sh) { + newargv[0] = x86?my_context->box86path:my_context->box64path; printf_log(LOG_DEBUG, "argv[%d]=\"%s\"\n", 0, newargv[0]); for(int i=nextarg; i<argc; ++i) { printf_log(LOG_DEBUG, "argv[%d]=\"%s\"\n", 1+i-nextarg, argv[i]); |