chiark / gitweb /
mount-util: fix error propagation in fd_fdinfo_mnt_id()
authorLennart Poettering <lennart@poettering.net>
Thu, 23 Nov 2017 11:44:17 +0000 (12:44 +0100)
committerSven Eden <yamakuzure@gmx.net>
Thu, 23 Nov 2017 11:44:17 +0000 (12:44 +0100)
src/basic/mount-util.c

index 640d3649b90db9f5269297c88c0296394f6d16e2..890bc41afb3764940ae1aed351bcdc7d74ab4ecc 100644 (file)
@@ -60,7 +60,7 @@ static int fd_fdinfo_mnt_id(int fd, const char *filename, int flags, int *mnt_id
         if (r == -ENOENT) /* The fdinfo directory is a relatively new addition */
                 return -EOPNOTSUPP;
         if (r < 0)
-                return -errno;
+                return r;
 
         p = startswith(fdinfo, "mnt_id:");
         if (!p) {