[libvirt] [PATCH 5/6] qemu: domain: Fix names for functions that clear security info

Peter Krempa pkrempa at redhat.com
Mon May 16 08:37:22 UTC 2016


On Fri, May 13, 2016 at 14:04:51 -0400, John Ferlan wrote:
> 
> 
> On 05/13/2016 12:04 PM, Peter Krempa wrote:
> > They don't free the structure itself so they should be called *Clear
> > rather than *Free.
> > ---
> >  src/qemu/qemu_domain.c | 8 ++++----
> >  1 file changed, 4 insertions(+), 4 deletions(-)
> > 
> > diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
> > index 87f0dbd..7e741a7 100644
> > --- a/src/qemu/qemu_domain.c
> > +++ b/src/qemu/qemu_domain.c
> > @@ -728,7 +728,7 @@ qemuDomainMasterKeyCreate(virDomainObjPtr vm)
> > 
> > 
> >  static void
> > -qemuDomainSecretPlainFree(qemuDomainSecretPlain secret)
> > +qemuDomainSecretPlainClear(qemuDomainSecretPlain secret)
> >  {
> >      VIR_FREE(secret.username);
> >      memset(secret.secret, 0, strlen(secret.secret));
> 
> This should use the new VIR_DISPOSE_N

Not in the patch that is fixing function names.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20160516/3c3fd518/attachment-0001.sig>


More information about the libvir-list mailing list