qemu-ga patch queue for 3.1.0
* add missing #include guards for guest-agent-core.h * fix leaks introduced with recent win32 enablement of disk info in guest-get-fsinfo -----BEGIN PGP SIGNATURE----- iQFOBAABCgA4FiEEzqzJ4VU066u4LT+gM1PJzvEItYQFAlvqPFwaHG1kcm90aEBs aW51eC52bmV0LmlibS5jb20ACgkQM1PJzvEItYSyxgf/WWcr/kKt8I+34SgrHudB LCUJ4LSH9fPrceetZL1GOa3Jl6Q0FGZCBhJpw0LaSjCyeGhFV2HUEDzVsXdtnAfA ++p4fQiT7WrPgR/oamv3tEqM1BxvdC8mFKaBo+ldAKEQglE9/fJ6P7e8tSMKlBuW rH17pJ7eVuLssZSmzBa/+2GOZHeoTR70Y0LtOuSY5s//lgCNCCmhO7H6i3CHLEZA ZFLMxuloAoKaSDgjJUjHI1l6uWU36RUs9uCDQFL/Ez0w7L4c5KuSdPcCl18dB3hl hr33kDQrz4m1MU3ngw8jUmndBiDx8DgZiP3KfL96d8aJ1sItatwjf5NmEiJR+YyK kg== =6301 -----END PGP SIGNATURE----- Merge remote-tracking branch 'remotes/mdroth/tags/qga-pull-2018-11-12-tag' into staging qemu-ga patch queue for 3.1.0 * add missing #include guards for guest-agent-core.h * fix leaks introduced with recent win32 enablement of disk info in guest-get-fsinfo # gpg: Signature made Tue 13 Nov 2018 02:52:12 GMT # gpg: using RSA key 3353C9CEF108B584 # gpg: Good signature from "Michael Roth <flukshun@gmail.com>" # gpg: aka "Michael Roth <mdroth@utexas.edu>" # gpg: aka "Michael Roth <mdroth@linux.vnet.ibm.com>" # Primary key fingerprint: CEAC C9E1 5534 EBAB B82D 3FA0 3353 C9CE F108 B584 * remotes/mdroth/tags/qga-pull-2018-11-12-tag: qga: Add multiple include guard to guest-agent-core.h qga-win: fix leaks of build_guest_disk_info() Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
commit
6ff1446989
@ -797,7 +797,7 @@ static GuestDiskAddressList *build_guest_disk_info(char *guid, Error **errp)
|
|||||||
0, extents, size, NULL, NULL)) {
|
0, extents, size, NULL, NULL)) {
|
||||||
error_setg_win32(errp, GetLastError(),
|
error_setg_win32(errp, GetLastError(),
|
||||||
"failed to get disk extents");
|
"failed to get disk extents");
|
||||||
return NULL;
|
goto out;
|
||||||
}
|
}
|
||||||
} else if (last_err == ERROR_INVALID_FUNCTION) {
|
} else if (last_err == ERROR_INVALID_FUNCTION) {
|
||||||
/* Possibly CD-ROM or a shared drive. Try to pass the volume */
|
/* Possibly CD-ROM or a shared drive. Try to pass the volume */
|
||||||
@ -855,6 +855,9 @@ static GuestDiskAddressList *build_guest_disk_info(char *guid, Error **errp)
|
|||||||
|
|
||||||
|
|
||||||
out:
|
out:
|
||||||
|
if (vol_h != INVALID_HANDLE_VALUE) {
|
||||||
|
CloseHandle(vol_h);
|
||||||
|
}
|
||||||
qapi_free_GuestDiskAddress(disk);
|
qapi_free_GuestDiskAddress(disk);
|
||||||
g_free(extents);
|
g_free(extents);
|
||||||
g_free(name);
|
g_free(name);
|
||||||
|
@ -10,6 +10,9 @@
|
|||||||
* This work is licensed under the terms of the GNU GPL, version 2 or later.
|
* This work is licensed under the terms of the GNU GPL, version 2 or later.
|
||||||
* See the COPYING file in the top-level directory.
|
* See the COPYING file in the top-level directory.
|
||||||
*/
|
*/
|
||||||
|
#ifndef GUEST_AGENT_CORE_H
|
||||||
|
#define GUEST_AGENT_CORE_H
|
||||||
|
|
||||||
#include "qapi/qmp/dispatch.h"
|
#include "qapi/qmp/dispatch.h"
|
||||||
#include "qemu-common.h"
|
#include "qemu-common.h"
|
||||||
#include "qga-qapi-types.h"
|
#include "qga-qapi-types.h"
|
||||||
@ -46,3 +49,5 @@ int ga_parse_whence(GuestFileWhence *whence, Error **errp);
|
|||||||
#ifndef _WIN32
|
#ifndef _WIN32
|
||||||
void reopen_fd_to_null(int fd);
|
void reopen_fd_to_null(int fd);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif /* GUEST_AGENT_CORE_H */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user