aboutsummaryrefslogtreecommitdiffstats
path: root/src/main.c
diff options
context:
space:
mode:
authorMichal Nazarewicz <mina86@mina86.com>2009-07-19 08:17:55 +0200
committerMax Kellermann <max@duempel.org>2009-07-19 08:17:55 +0200
commitd718a8b59d1f48abcff7f5626a237c1998fc83d5 (patch)
tree746fd0eb526ece35f71d8c5ca0f480ba107ec11d /src/main.c
parent4100035b19a5d0dedcf8f71a272fa67f6a24361a (diff)
downloadmpd-d718a8b59d1f48abcff7f5626a237c1998fc83d5.tar.gz
mpd-d718a8b59d1f48abcff7f5626a237c1998fc83d5.tar.xz
mpd-d718a8b59d1f48abcff7f5626a237c1998fc83d5.zip
daemon: added "group" configuration option
The "group" configuration option is similar to "user" as it sets user set what group MPD shall run as. With "user" option, MPD changed GID to the GID of the user, however, more control could be desired. Moreover, the patch changes the way of checking whether no setuid(2)/setgid(2) is required -- previously user names were compered, now UID and GIDs are compered (ie. the one we already have (getuid(2)/getgid(2)) with the one we want to change to).
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index 3d0aaabc9..54b31c1f8 100644
--- a/src/main.c
+++ b/src/main.c
@@ -94,6 +94,7 @@ static void
glue_daemonize_init(const struct options *options)
{
daemonize_init(config_get_string(CONF_USER, NULL),
+ config_get_string(CONF_GROUP, NULL),
config_get_path(CONF_PID_FILE));
if (options->kill)