diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/main.cc | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/main.cc b/src/main.cc index ae2b98c..9da51ec 100644 --- a/src/main.cc +++ b/src/main.cc | |||
@@ -325,11 +325,8 @@ int main(int argc, char **argv) { | |||
325 | if (!shell) | 325 | if (!shell) |
326 | shell = "/bin/sh"; | 326 | shell = "/bin/sh"; |
327 | 327 | ||
328 | const char *arg = restart_argument.c_str(); | 328 | execlp(shell, shell, "-c", restart_argument.c_str(), (const char *) NULL); |
329 | if (arg) { | 329 | perror(restart_argument.c_str()); |
330 | execlp(shell, shell, "-c", arg, (const char *) NULL); | ||
331 | perror(arg); | ||
332 | } | ||
333 | } | 330 | } |
334 | 331 | ||
335 | // fall back in case the above execlp doesn't work | 332 | // fall back in case the above execlp doesn't work |