mirror of https://gitee.com/openkylin/libvirt.git
Fix secret_driver compile warning, bug.
Set def to NULL in secretLoad(), otherwise we can access a random pointer on error. Signed-off-by: Chris Lalancette <clalance@redhat.com>
This commit is contained in:
parent
580ad29288
commit
ce37c3a109
|
@ -432,7 +432,7 @@ static virSecretEntryPtr
|
|||
secretLoad(virConnectPtr conn, virSecretDriverStatePtr driver,
|
||||
const char *xml_basename)
|
||||
{
|
||||
virSecretDefPtr def;
|
||||
virSecretDefPtr def = NULL;
|
||||
virSecretEntryPtr secret = NULL, ret = NULL;
|
||||
char *xml_filename;
|
||||
|
||||
|
|
Loading…
Reference in New Issue