mount-util: fix fd_is_mount_point() when both the parent and directory are network fs
authorFranck Bui <fbui@suse.com>
Thu, 30 Sep 2021 12:05:36 +0000 (14:05 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 12 Oct 2021 16:05:25 +0000 (18:05 +0200)
commita59bde3c5a4d46bc0589f0b94010cba1b55bbced
tree0ef1b85b29903d79eec5ef7ecaf679957daee407
parent44f372aa699a8d2a53a842e7ca3c2626c7117beb
mount-util: fix fd_is_mount_point() when both the parent and directory are network fs

The second call to name_to_handle_at_loop() didn't check for the specific
errors that can happen when the parent dir is mounted by nfs and instead of
falling back like it's done for the child dir, fd_is_mount_point() failed in
this case.

(cherry picked from commit 964ccab8286a7e75d7e9107f574f5cb23752bd5d)
(cherry picked from commit 8de173ff933510200ac3db77f1ae713f2c4acdc3)
src/basic/mountpoint-util.c