"Tim Schwartz" tim@sanityinternet.com wrote:
- GetServiceDisplayName(SCManager, service_name, NULL, &buffer_size);
- if(!buffer_size)
You need to check the GetServiceDisplayName retrun value, not buffer_size. If GetServiceDisplayName succeeds buffer_size contains valid length.
Also please numerate your retries, like "Take 3" or something like that.