aboutsummaryrefslogtreecommitdiff
path: root/qga/commands-win32.c
diff options
context:
space:
mode:
authorStefan Weil <sw@weilnetz.de>2013-11-25 20:54:17 +0100
committerAnthony Liguori <aliguori@amazon.com>2013-11-25 20:35:28 -0800
commit16f4e8fa737b58b7b0461b33581e43ac06991110 (patch)
treea91151d75e872419a7a307131b5b33db07b219ac /qga/commands-win32.c
parent84dc96e1e51c74ebf40b6c5e0c383769402e1a2d (diff)
qga: Fix two format strings for MinGW
Both code locations cause a compiler warning. Using "%s" instead of "%lu" would result in a program crash if the wrong code were executed. Signed-off-by: Stefan Weil <sw@weilnetz.de> Message-id: 1385409257-2522-1-git-send-email-sw@weilnetz.de Signed-off-by: Anthony Liguori <aliguori@amazon.com>
Diffstat (limited to 'qga/commands-win32.c')
-rw-r--r--qga/commands-win32.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/qga/commands-win32.c b/qga/commands-win32.c
index 7a37f5cadd..a6a0af264b 100644
--- a/qga/commands-win32.c
+++ b/qga/commands-win32.c
@@ -110,7 +110,7 @@ void qmp_guest_shutdown(bool has_mode, const char *mode, Error **err)
}
if (!ExitWindowsEx(shutdown_flag, SHTDN_REASON_FLAG_PLANNED)) {
- slog("guest-shutdown failed: %d", GetLastError());
+ slog("guest-shutdown failed: %lu", GetLastError());
error_set(err, QERR_UNDEFINED_ERROR);
}
}
@@ -301,7 +301,7 @@ static DWORD WINAPI do_suspend(LPVOID opaque)
DWORD ret = 0;
if (!SetSuspendState(*mode == GUEST_SUSPEND_MODE_DISK, TRUE, TRUE)) {
- slog("failed to suspend guest, %s", GetLastError());
+ slog("failed to suspend guest, %lu", GetLastError());
ret = -1;
}
g_free(mode);