performance fixes on win32 plus clean up of some warnings. also

improved error messages when uninstalling service.
This commit is contained in:
crs
2002-06-14 18:08:20 +00:00
parent 21af7b2f17
commit e3dcf7febf
21 changed files with 340 additions and 177 deletions

View File

@@ -35,12 +35,12 @@ CUnixPlatform::installDaemon(
return true;
}
bool
CUnixPlatform::EResult
CUnixPlatform::uninstallDaemon(
const char*)
{
// daemons don't require special installation
return true;
return kSuccess;
}
int
@@ -85,12 +85,20 @@ CUnixPlatform::daemonize(
dup(1);
// hook up logger
setDaemonLogger(name);
installDaemonLogger(name);
// invoke function
return func(this, 1, &name);
}
void
CUnixPlatform::installDaemonLogger(
const char* name)
{
openlog(name, 0, LOG_DAEMON);
CLog::setOutputter(&CUnixPlatform::deamonLogger);
}
int
CUnixPlatform::restart(
RestartFunc func,
@@ -195,14 +203,6 @@ CUnixPlatform::addPathComponent(
return path;
}
void
CUnixPlatform::setDaemonLogger(
const char* name)
{
openlog(name, 0, LOG_DAEMON);
CLog::setOutputter(&CUnixPlatform::deamonLogger);
}
bool
CUnixPlatform::deamonLogger(
int priority,