aboutsummaryrefslogtreecommitdiff
path: root/console-tools
diff options
context:
space:
mode:
authorMatt Kraai <kraai@debian.org>2000-07-12 00:53:06 +0000
committerMatt Kraai <kraai@debian.org>2000-07-12 00:53:06 +0000
commite714bce003a1b0e2c49e58fe14af86abc8b31f23 (patch)
tree83dc60ba6291ab2839a8eeca47076582578841c7 /console-tools
parent3ecbe9f4dca998d224760f537dc1c3fd7269893b (diff)
downloadbusybox-w32-e714bce003a1b0e2c49e58fe14af86abc8b31f23.tar.gz
busybox-w32-e714bce003a1b0e2c49e58fe14af86abc8b31f23.tar.bz2
busybox-w32-e714bce003a1b0e2c49e58fe14af86abc8b31f23.zip
Use global applet_name instead of local versions.
Diffstat (limited to 'console-tools')
-rw-r--r--console-tools/deallocvt.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/console-tools/deallocvt.c b/console-tools/deallocvt.c
index 0cad7717b..53d4d9a7c 100644
--- a/console-tools/deallocvt.c
+++ b/console-tools/deallocvt.c
@@ -14,8 +14,6 @@
14#define VT_DISALLOCATE 0x5608 /* free memory associated to vt */ 14#define VT_DISALLOCATE 0x5608 /* free memory associated to vt */
15 15
16 16
17char *progname;
18
19int deallocvt_main(int argc, char *argv[]) 17int deallocvt_main(int argc, char *argv[])
20{ 18{
21 int fd, num, i; 19 int fd, num, i;
@@ -29,8 +27,6 @@ int deallocvt_main(int argc, char *argv[])
29 ); 27 );
30 } 28 }
31 29
32 progname = argv[0];
33
34 fd = get_console_fd("/dev/console"); 30 fd = get_console_fd("/dev/console");
35 31
36 if (argc == 1) { 32 if (argc == 1) {
@@ -43,14 +39,14 @@ int deallocvt_main(int argc, char *argv[])
43 for (i = 1; i < argc; i++) { 39 for (i = 1; i < argc; i++) {
44 num = atoi(argv[i]); 40 num = atoi(argv[i]);
45 if (num == 0) 41 if (num == 0)
46 fprintf(stderr, "%s: 0: illegal VT number\n", progname); 42 fprintf(stderr, "%s: 0: illegal VT number\n", applet_name);
47 else if (num == 1) 43 else if (num == 1)
48 fprintf(stderr, "%s: VT 1 cannot be deallocated\n", 44 fprintf(stderr, "%s: VT 1 cannot be deallocated\n",
49 progname); 45 applet_name);
50 else if (ioctl(fd, VT_DISALLOCATE, num)) { 46 else if (ioctl(fd, VT_DISALLOCATE, num)) {
51 perror("VT_DISALLOCATE"); 47 perror("VT_DISALLOCATE");
52 fprintf(stderr, "%s: could not deallocate console %d\n", 48 fprintf(stderr, "%s: could not deallocate console %d\n",
53 progname, num); 49 applet_name, num);
54 exit( FALSE); 50 exit( FALSE);
55 } 51 }
56 } 52 }