提交 3eb84090 编写于 作者: M Michal Privoznik

qemuStateInitialize: Don't leak @memoryBackingPath

==899== 39 bytes in 1 blocks are definitely lost in loss record 732 of 1,003
==899==    at 0x4C2AEDF: malloc (vg_replace_malloc.c:299)
==899==    by 0x8B68CE7: vasprintf (in /lib64/libc-2.25.so)
==899==    by 0x55498D2: virVasprintfInternal (virstring.c:708)
==899==    by 0x55499E7: virAsprintfInternal (virstring.c:729)
==899==    by 0x2BECFFF0: qemuGetMemoryBackingBasePath (qemu_conf.c:1757)
==899==    by 0x2BF23225: qemuStateInitialize (qemu_driver.c:893)
==899==    by 0x563073D: virStateInitialize (libvirt.c:770)
==899==    by 0x124CC4: daemonRunStateInit (libvirtd.c:834)
==899==    by 0x55521CD: virThreadHelper (virthread.c:206)
==899==    by 0x88D9686: start_thread (in /lib64/libpthread-2.25.so)
==899==    by 0x8BEAEFE: clone (in /lib64/libc-2.25.so)
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
上级 0fd85b98
...@@ -904,6 +904,7 @@ qemuStateInitialize(bool privileged, ...@@ -904,6 +904,7 @@ qemuStateInitialize(bool privileged,
virFileUpdatePerm(memoryBackingPath, virFileUpdatePerm(memoryBackingPath,
0, S_IXGRP | S_IXOTH) < 0) 0, S_IXGRP | S_IXOTH) < 0)
goto error; goto error;
VIR_FREE(memoryBackingPath);
if (!(qemu_driver->closeCallbacks = virCloseCallbacksNew())) if (!(qemu_driver->closeCallbacks = virCloseCallbacksNew()))
goto error; goto error;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册