diff options
author | Glenn L McGrath <bug1@ihug.co.nz> | 2004-01-08 10:51:09 +0000 |
---|---|---|
committer | Glenn L McGrath <bug1@ihug.co.nz> | 2004-01-08 10:51:09 +0000 |
commit | 95f75a3dcdbdf78fbb30d2a2e3e7777ee8ba1129 (patch) | |
tree | 52790a2243d4f0d526c54cad36744401a1337b23 /coreutils | |
parent | 1f28b90a9c934a2e56e50da279bfca136b802114 (diff) | |
download | busybox-95f75a3dcdbdf78fbb30d2a2e3e7777ee8ba1129.tar.gz |
Patch from Bastian Blank to fix debian bug #226722, test case:
mkdir foo
touch foo/bar
ln -s bar foo/baz
Diffstat (limited to 'coreutils')
-rw-r--r-- | coreutils/ln.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/coreutils/ln.c b/coreutils/ln.c index 0640c6666..7c282b001 100644 --- a/coreutils/ln.c +++ b/coreutils/ln.c @@ -73,8 +73,7 @@ extern int ln_main(int argc, char **argv) free(src_name); src_name = src; } - - if (stat(*argv, &statbuf)) { + if (!(flag & LN_SYMLINK) && stat(*argv, &statbuf)) { bb_perror_msg(*argv); status = EXIT_FAILURE; free(src_name); @@ -101,13 +100,3 @@ extern int ln_main(int argc, char **argv) return status; } - - - - - - - - - - |