• E
    screenshot: don't unlink bogus file · 440d6b6a
    Eric Blake 提交于
    The previous qemu patch could end up calling unlink(tmp) before
    tmp was the name of a valid file (unlinking a fileXXXXXX template
    instead), or calling unlink(tmp) twice on success (once here,
    and once at the end of the stream).  Meanwhile, vbox also suffered
    from the same leaked tmp file bug.
    
    * src/qemu/qemu_driver.c (qemuDomainScreenshot): Don't unlink on
    success, or on invalid name.
    * src/vbox/vbox_tmpl.c (vboxDomainScreenshot): Don't leak temp file.
    440d6b6a
qemu_driver.c 290.2 KB