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

Re: [libvirt] [PATCH v2] qemu: monitor: Fix a memory leak in qemuMonitorJSONAttachCharDevCommand



On Wed, Jun 14, 2017 at 09:10:15AM +0200, Erik Skultety wrote:
> With the current logic, we only free @tlsalias as part of the error
> label and would have to free it explicitly earlier in the code. Convert
> the error label to cleanup, so that we have only one sink, where we
> handle all frees. Since since JSON object append operation consumes

s/Since since/Since/

> pointers, make sure @backend is cleared before we hit the cleanup label.
> 
> Signed-off-by: Erik Skultety <eskultet redhat com>
> ---
>  src/qemu/qemu_monitor_json.c | 41 ++++++++++++++++++++---------------------
>  1 file changed, 20 insertions(+), 21 deletions(-)

Reviewed-by: Pavel Hrdina <phrdina redhat com>

Attachment: signature.asc
Description: Digital signature


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