diff options
Diffstat (limited to 'src/shared/loop-util.c')
-rw-r--r-- | src/shared/loop-util.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shared/loop-util.c b/src/shared/loop-util.c index 3396cf5..ef35e31 100644 --- a/src/shared/loop-util.c +++ b/src/shared/loop-util.c @@ -637,7 +637,7 @@ int loop_device_make_by_path( else direct = direct_flags != 0; if (fd < 0) { - r = -errno; + r = fd; /* Retry read-only? */ if (open_flags >= 0 || !(ERRNO_IS_PRIVILEGE(r) || r == -EROFS)) |