mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
lxc: free 'ttyFDs' array on return from lxcVmStart
Detected by Coverity. Leak introduced in commit 0f31f7b.
* src/lxc/lxc_driver.c: Clean up on failure.
Signed-off-by: Alex Jia <ajia@redhat.com>
This commit is contained in:
committed by
Michal Privoznik
parent
5ab243b64f
commit
b9338ac828
@@ -1850,6 +1850,7 @@ cleanup:
|
||||
}
|
||||
for (i = 0 ; i < nttyFDs ; i++)
|
||||
VIR_FORCE_CLOSE(ttyFDs[i]);
|
||||
VIR_FREE(ttyFDs);
|
||||
VIR_FORCE_CLOSE(handshakefds[0]);
|
||||
VIR_FORCE_CLOSE(handshakefds[1]);
|
||||
VIR_FREE(logfile);
|
||||
|
||||
Reference in New Issue
Block a user