bootctl: log correct error about device_path_make_canonical()

This commit is contained in:
Mike Yuan
2023-06-23 23:57:49 +08:00
parent 1923373a64
commit 93d82cfcae
+3 -1
View File
@@ -479,7 +479,9 @@ static int run(int argc, char *argv[]) {
r = device_path_make_canonical(S_IFBLK, devno, &path);
if (r < 0)
return log_oom();
return log_error_errno(r,
"Failed to format canonical device path for devno '" DEVNUM_FORMAT_STR "': %m",
DEVNUM_FORMAT_VAL(devno));
puts(path);
return 0;