]> sourceware.org Git - lvm2.git/commit
fix duplicate pv size check
authorDavid Teigland <teigland@redhat.com>
Tue, 27 Aug 2019 20:40:24 +0000 (15:40 -0500)
committerDavid Teigland <teigland@redhat.com>
Tue, 27 Aug 2019 20:40:24 +0000 (15:40 -0500)
commitdcbed38b3339ce4da722bccec8eaf7b8d775a6c2
tree1e16f258ba33bf5a35982493fbb4394ace235e1d
parent32a8865a272d31d5bc12332a4da0309ce3af9243
fix duplicate pv size check

Fixes a segfault in the recent commit e01fddc57:
"improve duplicate pv handling for md components"

While choosing between duplicates, the info struct is
not always valid; it may have been dropped already.

Remove the code that was still using the info struct for
size comparisons.  The size comparisons were a bogus check
anyway because it was just preferring the dev that had
already been chosen, it wasn't actually comparing the
dev size to the PV size.  It would be good to use a
dev/PV size comparison in the duplicate handling code, but
the PV size is not available until after vg_read, not
from the scan.
lib/cache/lvmcache.c
This page took 0.037281 seconds and 5 git commands to generate.