[LTP] [PATCH] fs_bind: Fix incorrect mount option

Petr Vorel pvorel@suse.cz
Tue Aug 9 07:11:26 CEST 2022


Hi Dylan,

> Hi Petr:

> Thanks for the review.

> >>>>> I wonder why test didn't failed (at least on SUT I tested it).
> Some mount command implementations[*1] use getopt_long() to parse mount 
> options, but getopt_long() seems to treat "--make-share" and "--make-shared"
> as the same option.

> The error I encounter this time is using busybox's mount command[*2], which 
> uses strncasecmp() to parse the argements, It will treat "--make-share" and 
> "--make-shared" as different options.

> According to the manual of mount command, "--make-shared" should be the correct
> option.

> reference:
>     [*1] https://kernel.googlesource.com/pub/scm/utils/util-linux/util-linux/+/stable/v2.13/mount/mount.c#1816
>     [*2] https://github.com/brgl/busybox/blob/master/util-linux/mount.c#L372
>     [*3] https://linux.die.net/man/8/mount

Thanks for info. Please next time include this in the commit message
(useful info, but as I wrote yesterday I already merged your commit).

Kind regards,
Petr

> Best,
> Dylan

> On Mon, Aug 08, 2022 at 08:53:09PM +0800, Petr Vorel wrote:
> > Hi Dylan,

> > Reviewed-by: Petr Vorel <pvorel@suse.cz>

> > I wonder why test didn't failed (at least on SUT I tested it).

> > Kind regards,
> > Petr


More information about the ltp mailing list