dissect: use SYNTHETIC_ERRNO() where appropriate
This commit is contained in:
parent
46bba8a51c
commit
59ba6d0c17
|
@ -343,10 +343,8 @@ int dissect_image(
|
||||||
|
|
||||||
errno = 0;
|
errno = 0;
|
||||||
r = blkid_do_safeprobe(b);
|
r = blkid_do_safeprobe(b);
|
||||||
if (IN_SET(r, -2, 1)) {
|
if (IN_SET(r, -2, 1))
|
||||||
log_debug("Failed to identify any partition table.");
|
return log_debug_errno(SYNTHETIC_ERRNO(ENOPKG), "Failed to identify any partition table.");
|
||||||
return -ENOPKG;
|
|
||||||
}
|
|
||||||
if (r != 0)
|
if (r != 0)
|
||||||
return -errno ?: -EIO;
|
return -errno ?: -EIO;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue