]> sourceware.org Git - lvm2.git/commit
Fix possible NULL pointer dereferences when updating mirror log.
authorJonathan Earl Brassow <jbrassow@redhat.com>
Mon, 13 Feb 2012 18:36:55 +0000 (18:36 +0000)
committerJonathan Earl Brassow <jbrassow@redhat.com>
Mon, 13 Feb 2012 18:36:55 +0000 (18:36 +0000)
commit1456c3b298af2e09657a1d46b8e75523786df270
tree1f076a42beef3628bce50fb6867cb5fb426a3b4a
parenta30832cedd7a844740dc6047597e0cf3b8cbb1e2
Fix possible NULL pointer dereferences when updating mirror log.

'_lv_update_log_type' takes a lvconvert_params argument so that it can pass
down the user's preference of 'region_size' and allocation_policy.  When
'mirror_remove_missing' was introduced (commit ID
95986e42a18ca98c9b1d777346978b7297c85558) it didn't make sense to pass down
user preferences - so NULL was given instead.  While it may never happen in
practice, static analysis reveals that this argument could be dereferenced.
So, if the user preferences were not passed in, glean the necessary fields
from what is already set in the LV.

Reported-by: Zdenek Kabelac <zkabelac@redhat.com>
Signed-off-by: Jonathan Brassow <jbrassow@redhat.com>
(Not updating WHATSNEW for this simple clean-up.)
tools/lvconvert.c
This page took 0.02998 seconds and 5 git commands to generate.