1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-20 18:09:23 +03:00

device_mapper: check for pv before use in error msg

This commit is contained in:
Zdenek Kabelac 2024-10-24 22:38:14 +02:00
parent 875012fb5d
commit 188dd3c357

View File

@ -498,7 +498,7 @@ static int _get_pv_idx(const struct formatter *f, const struct physical_volume *
if (!pv || !radix_tree_lookup(f->pv_idx, &pv, sizeof(pv), &idx)) {
log_error(INTERNAL_ERROR "PV name for %s missing in metadata export radix tree.",
pv_dev_name(pv));
(pv) ? pv_dev_name(pv) : "");
return -1;
}