diff --git a/libsysfs/sysfs_utils.c b/libsysfs/sysfs_utils.c index bd7f99ae15d..c5558a43a1e 100644 --- a/libsysfs/sysfs_utils.c +++ b/libsysfs/sysfs_utils.c @@ -233,7 +233,7 @@ int sysfs_path_is_dir(const char *path) errno = EINVAL; return 1; } - if ((stat(path, &astats)) != 0) { + if ((lstat(path, &astats)) != 0) { dprintf("stat() failed\n"); return 1; }