[PATCH] ln: --no-target-directory implies --no-dereference

Denys Vlasenko vda.linux at googlemail.com
Tue Oct 8 12:08:43 UTC 2019


Applied, thanks

On Mon, Oct 7, 2019 at 6:34 PM Kaarle Ritvanen
<kaarle.ritvanen at datakunkku.fi> wrote:
>
> as in GNU coreutils
> ---
>  coreutils/ln.c | 5 +----
>  1 file changed, 1 insertion(+), 4 deletions(-)
>
> diff --git a/coreutils/ln.c b/coreutils/ln.c
> index ea2d10eab..f2a1941b9 100644
> --- a/coreutils/ln.c
> +++ b/coreutils/ln.c
> @@ -85,10 +85,7 @@ int ln_main(int argc, char **argv)
>                 src_name = NULL;
>                 src = last;
>
> -               if (is_directory(src,
> -                               (opts & LN_NODEREFERENCE) ^ LN_NODEREFERENCE
> -                               )
> -               ) {
> +               if (is_directory(src, !(opts & (LN_NODEREFERENCE|LN_LINKFILE)))) {
>                         if (opts & LN_LINKFILE) {
>                                 bb_error_msg_and_die("'%s' is a directory", src);
>                         }
> --
> 2.20.1
>
> _______________________________________________
> busybox mailing list
> busybox at busybox.net
> http://lists.busybox.net/mailman/listinfo/busybox


More information about the busybox mailing list