diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2009-11-28 15:18:53 +0100 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2009-11-28 15:18:53 +0100 |
commit | e992bae6f9adf3718c6263a36c004ead1c7272a8 (patch) | |
tree | f0bc9e4fa145f58ab3f9838902e09f9cfba29648 /miscutils/rx.c | |
parent | 86cfb70ca5f2bde11f2d071bc59db75291d8552f (diff) | |
download | busybox-w32-e992bae6f9adf3718c6263a36c004ead1c7272a8.tar.gz busybox-w32-e992bae6f9adf3718c6263a36c004ead1c7272a8.tar.bz2 busybox-w32-e992bae6f9adf3718c6263a36c004ead1c7272a8.zip |
*: remove a few more cases of argc usage. -89 bytes.
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'miscutils/rx.c')
-rw-r--r-- | miscutils/rx.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/miscutils/rx.c b/miscutils/rx.c index 3a8b6a8fe..4c5d5a19c 100644 --- a/miscutils/rx.c +++ b/miscutils/rx.c | |||
@@ -234,21 +234,18 @@ static void sigalrm_handler(int UNUSED_PARAM signum) | |||
234 | } | 234 | } |
235 | 235 | ||
236 | int rx_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 236 | int rx_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
237 | int rx_main(int argc, char **argv) | 237 | int rx_main(int argc UNUSED_PARAM, char **argv) |
238 | { | 238 | { |
239 | struct termios tty, orig_tty; | 239 | struct termios tty, orig_tty; |
240 | int termios_err; | 240 | int termios_err; |
241 | int file_fd; | 241 | int file_fd; |
242 | int n; | 242 | int n; |
243 | 243 | ||
244 | if (argc != 2) | ||
245 | bb_show_usage(); | ||
246 | |||
247 | /* Disabled by vda: | 244 | /* Disabled by vda: |
248 | * why we can't receive from stdin? Why we *require* | 245 | * why we can't receive from stdin? Why we *require* |
249 | * controlling tty?? */ | 246 | * controlling tty?? */ |
250 | /*read_fd = xopen(CURRENT_TTY, O_RDWR);*/ | 247 | /*read_fd = xopen(CURRENT_TTY, O_RDWR);*/ |
251 | file_fd = xopen(argv[1], O_RDWR|O_CREAT|O_TRUNC); | 248 | file_fd = xopen(single_argv(argv), O_RDWR|O_CREAT|O_TRUNC); |
252 | 249 | ||
253 | termios_err = tcgetattr(read_fd, &tty); | 250 | termios_err = tcgetattr(read_fd, &tty); |
254 | if (termios_err == 0) { | 251 | if (termios_err == 0) { |