blockdev-util: change return value when a partition device is passed to partition_enumerator_new()
To make it consistent what returned by block_device_get_whole_disk().
This commit is contained in:
@@ -572,7 +572,7 @@ int partition_enumerator_new(sd_device *dev, sd_device_enumerator **ret) {
|
||||
if (r < 0)
|
||||
return r;
|
||||
if (r == 0)
|
||||
return -EINVAL;
|
||||
return -ENXIO; /* return a recognizable error */
|
||||
|
||||
r = sd_device_enumerator_new(&e);
|
||||
if (r < 0)
|
||||
|
||||
Reference in New Issue
Block a user