On 07/28/2016 08:37 AM, marcandre.lur...@redhat.com wrote:
> From: Marc-André Lureau <marcandre.lur...@redhat.com>
> 
> chr_disconnect callback is used to cleanup server socket peer. This
> removes some leaks when the chardev is freed.
> 
> Signed-off-by: Marc-André Lureau <marcandre.lur...@redhat.com>
> ---
>  qemu-char.c | 1 +
>  1 file changed, 1 insertion(+)

Reviewed-by: Eric Blake <ebl...@redhat.com>

> 
> diff --git a/qemu-char.c b/qemu-char.c
> index e4b8448..6ed6dd6 100644
> --- a/qemu-char.c
> +++ b/qemu-char.c
> @@ -4031,6 +4031,7 @@ static void qemu_chr_free_common(CharDriverState *chr)
>  
>  void qemu_chr_free(CharDriverState *chr)
>  {
> +    qemu_chr_disconnect(chr);
>      if (chr->chr_close) {
>          chr->chr_close(chr);
>      }
> 

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to