remove the "exec " from the command for running menu stuff so that normal shell things work right in the menu
This commit is contained in:
parent
25a18140fa
commit
79916c273d
1 changed files with 2 additions and 4 deletions
|
@ -169,13 +169,11 @@ void bexec(const string& command, const string& displaystring) {
|
||||||
setsid();
|
setsid();
|
||||||
int ret = putenv(const_cast<char *>(displaystring.c_str()));
|
int ret = putenv(const_cast<char *>(displaystring.c_str()));
|
||||||
assert(ret != -1);
|
assert(ret != -1);
|
||||||
string cmd = "exec ";
|
ret = execl("/bin/sh", "/bin/sh", "-c", command.c_str(), NULL);
|
||||||
cmd += command;
|
|
||||||
ret = execl("/bin/sh", "/bin/sh", "-c", cmd.c_str(), NULL);
|
|
||||||
exit(ret);
|
exit(ret);
|
||||||
}
|
}
|
||||||
#else // __EMX__
|
#else // __EMX__
|
||||||
spawnlp(P_NOWAIT, "cmd.exe", "cmd.exe", "/c", command, NULL);
|
spawnlp(P_NOWAIT, "cmd.exe", "cmd.exe", "/c", command.c_str(), NULL);
|
||||||
#endif // !__EMX__
|
#endif // !__EMX__
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue