aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2000-09-05 18:21:53 +0000
committerEric Andersen <andersen@codepoet.org>2000-09-05 18:21:53 +0000
commit1eec89df4c85f6c6fbf8fea962cd5b1d8029492d (patch)
tree787a2748d5c811d559e767a0858319bf8069a70d
parent3639c5d9509ff2c91dee55bbce290d87a49970d5 (diff)
downloadbusybox-w32-1eec89df4c85f6c6fbf8fea962cd5b1d8029492d.tar.gz
busybox-w32-1eec89df4c85f6c6fbf8fea962cd5b1d8029492d.tar.bz2
busybox-w32-1eec89df4c85f6c6fbf8fea962cd5b1d8029492d.zip
Apply segfault on no-args fix from robotti@metconnect.com
-rw-r--r--miscutils/mt.c2
-rw-r--r--mt.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/miscutils/mt.c b/miscutils/mt.c
index 087819e72..e77f58a6a 100644
--- a/miscutils/mt.c
+++ b/miscutils/mt.c
@@ -55,7 +55,7 @@ extern int mt_main(int argc, char **argv)
55 struct mtop op; 55 struct mtop op;
56 int fd; 56 int fd;
57 57
58 if ((argc != 2 && argc != 3) && **(argv + 1) != '-') { 58 if (argc < 2) {
59 usage(mt_usage); 59 usage(mt_usage);
60 } 60 }
61 61
diff --git a/mt.c b/mt.c
index 087819e72..e77f58a6a 100644
--- a/mt.c
+++ b/mt.c
@@ -55,7 +55,7 @@ extern int mt_main(int argc, char **argv)
55 struct mtop op; 55 struct mtop op;
56 int fd; 56 int fd;
57 57
58 if ((argc != 2 && argc != 3) && **(argv + 1) != '-') { 58 if (argc < 2) {
59 usage(mt_usage); 59 usage(mt_usage);
60 } 60 }
61 61