diff options
Diffstat (limited to 'console-tools/openvt.c')
-rw-r--r-- | console-tools/openvt.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/console-tools/openvt.c b/console-tools/openvt.c index ff169530d..39b985995 100644 --- a/console-tools/openvt.c +++ b/console-tools/openvt.c | |||
@@ -27,9 +27,10 @@ int openvt_main(int argc, char **argv) | |||
27 | /* grab new one */ | 27 | /* grab new one */ |
28 | close(0); | 28 | close(0); |
29 | xopen(vtname, O_RDWR); | 29 | xopen(vtname, O_RDWR); |
30 | dup2(0, STDOUT_FILENO); | 30 | xdup2(0, STDOUT_FILENO); |
31 | dup2(0, STDERR_FILENO); | 31 | xdup2(0, STDERR_FILENO); |
32 | 32 | ||
33 | BB_EXECVP(argv[2], &argv[2]); | 33 | argv += 2; |
34 | BB_EXECVP(argv[0], argv); | ||
34 | _exit(1); | 35 | _exit(1); |
35 | } | 36 | } |