summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMantas Mikulėnas <grawity@gmail.com>2012-09-09 15:16:19 +0300
committerLennart Poettering <lennart@poettering.net>2012-09-10 09:21:24 +0200
commitfa125f4e44aaf102548ab464e3ea457214fd56e0 (patch)
treed4178bea46e1cc8d8b697b2c90aa6222d1d96f1b /src
parent8ac7549330c774b8ca04034c1303165fe6a920b0 (diff)
path-util: fall back to stat() if kernel does not support name_to_handle_at()
Fixes instant hang on kernels that do not have CONFIG_FHANDLE enabled.
Diffstat (limited to 'src')
-rw-r--r--src/shared/path-util.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/shared/path-util.c b/src/shared/path-util.c
index 97a200504b..b51a68d6d2 100644
--- a/src/shared/path-util.c
+++ b/src/shared/path-util.c
@@ -349,8 +349,8 @@ int path_is_mount_point(const char *t, bool allow_symlink) {
r = name_to_handle_at(AT_FDCWD, t, h, &mount_id, allow_symlink ? AT_SYMLINK_FOLLOW : 0);
if (r < 0) {
- if (errno == ENOTSUP)
- /* This file system does not support
+ if (errno == ENOSYS || errno == ENOTSUP)
+ /* This kernel or file system does not support
* name_to_handle_at(), hence fallback to the
* traditional stat() logic */
goto fallback;