diff options
author | landley <landley@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2005-09-08 03:27:06 +0000 |
---|---|---|
committer | landley <landley@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2005-09-08 03:27:06 +0000 |
commit | 34fc9593c851077e268173538476ad31a8c6a0e5 (patch) | |
tree | c7b8e35296501484d82d6ac84ae1685df3339ccb /console-tools/chvt.c | |
parent | e30c75afb85b0b70571d1550ff4eddbf3044becb (diff) | |
download | busybox-w32-34fc9593c851077e268173538476ad31a8c6a0e5.tar.gz busybox-w32-34fc9593c851077e268173538476ad31a8c6a0e5.tar.bz2 busybox-w32-34fc9593c851077e268173538476ad31a8c6a0e5.zip |
Tito sent more size tweaks.
git-svn-id: svn://busybox.net/trunk/busybox@11390 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'console-tools/chvt.c')
-rw-r--r-- | console-tools/chvt.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/console-tools/chvt.c b/console-tools/chvt.c index 3398892f5..b1a429eb3 100644 --- a/console-tools/chvt.c +++ b/console-tools/chvt.c | |||
@@ -42,11 +42,9 @@ int chvt_main(int argc, char **argv) | |||
42 | 42 | ||
43 | fd = get_console_fd(); | 43 | fd = get_console_fd(); |
44 | num = bb_xgetlarg(argv[1], 10, 0, INT_MAX); | 44 | num = bb_xgetlarg(argv[1], 10, 0, INT_MAX); |
45 | if (ioctl(fd, VT_ACTIVATE, num)) { | 45 | if((-1 == ioctl(fd, VT_ACTIVATE, num)) || |
46 | bb_perror_msg_and_die("VT_ACTIVATE"); | 46 | (-1 == ioctl(fd, VT_WAITACTIVE, num))) { |
47 | } | 47 | bb_perror_msg_and_die("ioctl"); |
48 | if (ioctl(fd, VT_WAITACTIVE, num)) { | ||
49 | bb_perror_msg_and_die("VT_WAITACTIVE"); | ||
50 | } | 48 | } |
51 | return EXIT_SUCCESS; | 49 | return EXIT_SUCCESS; |
52 | } | 50 | } |