Improve error handling in scmdatabase_autostart_services. (RESEND)
Gerald Pfeifer
gerald at pfeifer.com
Fri May 7 13:36:15 CDT 2010
I noticed that we are not using the error code coming from service_start,
and indeed there was a FIXME there already. Would it make sense to handle
this (at least) somehow like the patch below?
If preferred, I could also yank the err variable, but I figured you'd
prefer the error handling. (Or is there a mistake I made when adding
that handling?)
Gerald
---
programs/services/services.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/programs/services/services.c b/programs/services/services.c
index a5eb2f7..bc2380e 100644
--- a/programs/services/services.c
+++ b/programs/services/services.c
@@ -266,7 +266,8 @@ static void scmdatabase_autostart_services(struct scmdatabase *db)
argv[0] = service->name;
argv[1] = NULL;
err = service_start(service, 1, argv);
- /* FIXME: do something if the service failed to start */
+ if (err != ERROR_SUCCESS)
+ WINE_ERR("Failed to start service %s\n", wine_dbgstr_w(service->name));
release_service(service);
}
--
1.6.6.2
More information about the wine-patches
mailing list