diff options
author | proski <proski@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2000-06-18 00:02:24 +0000 |
---|---|---|
committer | proski <proski@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2000-06-18 00:02:24 +0000 |
commit | 24f4443efa2909f1f68801758979a0c2b7172566 (patch) | |
tree | 04270a5888f7830bac49463bf21e51b118abdfcd | |
parent | 5c69dc07c93b5478449e5e8fc30fe10451b3d51f (diff) | |
download | busybox-w32-24f4443efa2909f1f68801758979a0c2b7172566.tar.gz busybox-w32-24f4443efa2909f1f68801758979a0c2b7172566.tar.bz2 busybox-w32-24f4443efa2909f1f68801758979a0c2b7172566.zip |
Check for 3 and more arguments was incorrect
It is only allowed for linking to a directory
But linking to a directory still fails and may be removed
git-svn-id: svn://busybox.net/trunk/busybox@656 69ca8d6d-28ef-0310-b511-8ec308f3f277
-rw-r--r-- | coreutils/ln.c | 2 | ||||
-rw-r--r-- | ln.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/coreutils/ln.c b/coreutils/ln.c index 634c9905d..371482251 100644 --- a/coreutils/ln.c +++ b/coreutils/ln.c | |||
@@ -96,7 +96,7 @@ extern int ln_main(int argc, char **argv) | |||
96 | 96 | ||
97 | linkIntoDirFlag = isDirectory(linkName, TRUE, NULL); | 97 | linkIntoDirFlag = isDirectory(linkName, TRUE, NULL); |
98 | 98 | ||
99 | if ((argc > 3) && !linkIntoDirFlag) { | 99 | if ((argc >= 3) && linkIntoDirFlag == FALSE) { |
100 | fprintf(stderr, not_a_directory, "ln", linkName); | 100 | fprintf(stderr, not_a_directory, "ln", linkName); |
101 | exit FALSE; | 101 | exit FALSE; |
102 | } | 102 | } |
@@ -96,7 +96,7 @@ extern int ln_main(int argc, char **argv) | |||
96 | 96 | ||
97 | linkIntoDirFlag = isDirectory(linkName, TRUE, NULL); | 97 | linkIntoDirFlag = isDirectory(linkName, TRUE, NULL); |
98 | 98 | ||
99 | if ((argc > 3) && !linkIntoDirFlag) { | 99 | if ((argc >= 3) && linkIntoDirFlag == FALSE) { |
100 | fprintf(stderr, not_a_directory, "ln", linkName); | 100 | fprintf(stderr, not_a_directory, "ln", linkName); |
101 | exit FALSE; | 101 | exit FALSE; |
102 | } | 102 | } |