summaryrefslogtreecommitdiff
path: root/qga/service-win32.c
diff options
context:
space:
mode:
authorLaszlo Ersek <lersek@redhat.com>2013-07-03 15:14:08 +0200
committerMichael Roth <mdroth@linux.vnet.ibm.com>2013-07-25 14:49:04 -0500
commitfebf1c49be1bd80d7c95653fc0caa87d250b2c72 (patch)
treea5a8d06e37d9bfc02f83a8d070f600fa33310bd9 /qga/service-win32.c
parentd2f5ea9704af781d4cf14e4be08bb4e37a180260 (diff)
qga/service-win32.c: diagnostic output should go to stderr
Acked-by: Michael Roth <mdroth@linux.vnet.ibm.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Laszlo Ersek <lersek@redhat.com> Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Diffstat (limited to 'qga/service-win32.c')
-rw-r--r--qga/service-win32.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/qga/service-win32.c b/qga/service-win32.c
index 02926abb28..6de8be46be 100644
--- a/qga/service-win32.c
+++ b/qga/service-win32.c
@@ -29,7 +29,7 @@ static int printf_win_error(const char *text)
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
(char *)&message, 0,
NULL);
- n = printf("%s. (Error: %d) %s", text, (int)err, message);
+ n = fprintf(stderr, "%s. (Error: %d) %s", text, (int)err, message);
LocalFree(message);
return n;
@@ -78,7 +78,7 @@ int ga_install_service(const char *path, const char *logfile,
SERVICE_DESCRIPTION desc = { (char *)QGA_SERVICE_DESCRIPTION };
ChangeServiceConfig2(service, SERVICE_CONFIG_DESCRIPTION, &desc);
- printf("Service was installed successfully.\n");
+ fprintf(stderr, "Service was installed successfully.\n");
} else {
printf_win_error("Failed to install service");
}
@@ -111,7 +111,7 @@ int ga_uninstall_service(void)
if (DeleteService(service) == FALSE) {
printf_win_error("Failed to delete service");
} else {
- printf("Service was deleted successfully.\n");
+ fprintf(stderr, "Service was deleted successfully.\n");
}
CloseServiceHandle(service);