configure: add option to set default user

The default user is root by default, which disables root dropping by
default. The user directive or the -u option can still be used to set
the user.
This commit is contained in:
Miroslav Lichvar
2014-04-09 16:28:44 +02:00
parent 3edd3fe5a4
commit ff31702f74
5 changed files with 20 additions and 10 deletions

2
main.c
View File

@@ -466,7 +466,7 @@ int main
if (!user) {
user = CNF_GetUser();
}
if (user) {
if (user && strcmp(user, "root")) {
SYS_DropRoot(user);
}