[systemd-devel] [PATCH 1/2] path-util: fix fd_is_mount_point

Thomas H.P. Andersen phomes at gmail.com
Sun Apr 26 11:22:36 PDT 2015


On Sun, Apr 26, 2015 at 7:58 PM, Shawn Landden <shawn at churchofgit.com> wrote:
> (coverity)
> ---
>  src/shared/path-util.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/shared/path-util.c b/src/shared/path-util.c
> index 925bb28..95bfafc 100644
> --- a/src/shared/path-util.c
> +++ b/src/shared/path-util.c
> @@ -627,7 +627,7 @@ fallback_fstat:
>              a.st_ino == b.st_ino)
>                  return 1;
>
> -        return check_st_dev && (a.st_dev != b.st_dev);
> +        return (check_st_dev && (a.st_dev != b.st_dev));
>  }

I committed a different fix for this a few hours ago. I initialize
check_st_dev to true so we do the st_dev comparison if mnt_id is not
supported by the kernel.


More information about the systemd-devel mailing list