mirror of
https://github.com/norohind/hans.git
synced 2025-06-02 16:41:02 +03:00
Fixed "not supported" error on Windows
This commit is contained in:
parent
74bad3b702
commit
032089ce7a
@ -195,12 +195,12 @@ void Worker::stop()
|
|||||||
|
|
||||||
void Worker::dropPrivileges()
|
void Worker::dropPrivileges()
|
||||||
{
|
{
|
||||||
#ifdef WIN32
|
|
||||||
throw Exception("not supported");
|
|
||||||
#else
|
|
||||||
if (uid <= 0 || privilegesDropped)
|
if (uid <= 0 || privilegesDropped)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
#ifdef WIN32
|
||||||
|
throw Exception("dropping privileges not supported");
|
||||||
|
#else
|
||||||
syslog(LOG_INFO, "dropping privileges");
|
syslog(LOG_INFO, "dropping privileges");
|
||||||
|
|
||||||
if (setgid(gid) == -1)
|
if (setgid(gid) == -1)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user