Re: [PATCH 1/3] qemuhotplugtest: Free monitor iff successfully initialized

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

 



On Mon, 2020-06-29 at 09:43 +0200, Michal Privoznik wrote:
> If initializing test monitor in testQemuHotplugCpuPrepare()
> fails, the control jumps to error label where
> testQemuHotplugCpuDataFree() is called. But since the data->mon
> is NULL due to aforementioned failure,
> qemuMonitorTestGetMonitor() dereferences a NULL pointer leading
> to a SIGSEGV.
> 
> Signed-off-by: Michal Privoznik <mprivozn@xxxxxxxxxx>
> ---
>  tests/qemuhotplugtest.c | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)

Reviewed-by: Andrea Bolognani <abologna@xxxxxxxxxx>

and safe for freeze.

-- 
Andrea Bolognani / Red Hat / Virtualization




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux