qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2] qemu: avoid memory leak while remove disk


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH v2] qemu: avoid memory leak while remove disk
Date: Fri, 4 Jan 2019 10:17:10 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.3.1

On 12/22/18 4:27 AM, w00426999 wrote:
> Memset vhost_dev to zero in the vhost_dev_cleanup function.
> This causes dev.vqs to be NULL, so that
> vqs does not free up space when calling the g_free function.
> This will result in a memory leak. But you can't release vqs
> directly in the vhost_dev_cleanup function, because vhost_net
> will also call this function, and vhost_net's vqs is assigned by array.
> In order to solve this problem, we first save the pointer of vqs,
> and release the space of vqs after vhost_dev_cleanup is called.
> 
> Signed-off-by: Jian Wang <address@hidden>

It appears that this is your first qemu contribution - welcome!

Your S-o-b tag uses a different spelling "Jian Wang" than your From:
line "w00426999".  You may want to address your git config settings so
that outgoing mail sets the From: line correctly (I'm not sure which
config settings are involved; I also know that sometimes you can't
control the actual mail From: such as when sending from an address that
undergoes list munging due to SPF settings, but in that case git can be
told to insert a From: in the message body that will override any From:
header).  Fixing it now will avoid having to add a .mailmap entry to tie
the two spellings together.

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3226
Virtualization:  qemu.org | libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]