From: Lennart Poettering Date: Wed, 23 Jan 2019 15:59:57 +0000 (+0100) Subject: dissect: use SYNTHETIC_ERRNO() where appropriate X-Git-Tag: v242-rc1~218^2~43 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=59ba6d0c1747270716a3c8e7877857b203beab38;p=thirdparty%2Fsystemd.git dissect: use SYNTHETIC_ERRNO() where appropriate --- diff --git a/src/shared/dissect-image.c b/src/shared/dissect-image.c index d3404870254..94df2fe255f 100644 --- a/src/shared/dissect-image.c +++ b/src/shared/dissect-image.c @@ -343,10 +343,8 @@ int dissect_image( errno = 0; r = blkid_do_safeprobe(b); - if (IN_SET(r, -2, 1)) { - log_debug("Failed to identify any partition table."); - return -ENOPKG; - } + if (IN_SET(r, -2, 1)) + return log_debug_errno(SYNTHETIC_ERRNO(ENOPKG), "Failed to identify any partition table."); if (r != 0) return -errno ?: -EIO;