diff options
Diffstat (limited to 'block/block-backend.c')
-rw-r--r-- | block/block-backend.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/block/block-backend.c b/block/block-backend.c index 2a8f3b55f8..60d37a0c3d 100644 --- a/block/block-backend.c +++ b/block/block-backend.c @@ -918,7 +918,8 @@ char *blk_get_attached_dev_id(BlockBackend *blk) } else if (dev->id) { return g_strdup(dev->id); } - return object_get_canonical_path(OBJECT(dev)); + + return object_get_canonical_path(OBJECT(dev)) ?: g_strdup(""); } /* |