]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
mount-tool: sd_device_get_sysattr_value() returns 0 on success 18684/head
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sat, 20 Feb 2021 19:34:37 +0000 (04:34 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Sat, 20 Feb 2021 19:40:23 +0000 (04:40 +0900)
src/mount/mount-tool.c

index c1be0e0afbe7cb55ca2118a83e9b103d6763bd55..153f67f93b3be5afcb172f03182f861245a035c8 100644 (file)
@@ -1197,7 +1197,7 @@ static int acquire_removable(sd_device *d) {
                 return 0;
 
         for (;;) {
-                if (sd_device_get_sysattr_value(d, "removable", &v) > 0)
+                if (sd_device_get_sysattr_value(d, "removable", &v) >= 0)
                         break;
 
                 if (sd_device_get_parent(d, &d) < 0)