sd-id128: make sd_id128_get_boot() and friend return -ENOMEDIUM
This commit is contained in:
@@ -148,6 +148,9 @@ _public_ int sd_id128_get_boot(sd_id128_t *ret) {
|
||||
r = id128_read("/proc/sys/kernel/random/boot_id", ID128_FORMAT_UUID, &saved_boot_id);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
if (sd_id128_is_null(saved_boot_id))
|
||||
return -ENOMEDIUM;
|
||||
}
|
||||
|
||||
*ret = saved_boot_id;
|
||||
|
||||
Reference in New Issue
Block a user