mirror of https://gitee.com/openkylin/libvirt.git
virSecretLookupParseSecret: Use g_steal_pointer
Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
f07f1c479a
commit
ece6cb354d
|
@ -90,8 +90,7 @@ virSecretLookupParseSecret(xmlNodePtr secretnode,
|
|||
}
|
||||
def->type = VIR_SECRET_LOOKUP_TYPE_UUID;
|
||||
} else {
|
||||
def->u.usage = usage;
|
||||
usage = NULL;
|
||||
def->u.usage = g_steal_pointer(&usage);
|
||||
def->type = VIR_SECRET_LOOKUP_TYPE_USAGE;
|
||||
}
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue