As noted by Gerrit Renker, when trying to extract help text from
./para_audiod, the build stops when logged in as root because
para_audiod refuses to start as root if --user and --group are
not given.
This patch moves the check for UID==0 after the check for --help and
--detailed-help so that the help text may be extracted as root even
if no --user and --group options are given.
valid_fd_012();
audiod_cmdline_parser_ext(argc, argv, &conf, ¶ms);
HANDLE_VERSION_FLAG("audiod", conf);
- drop_privileges_or_die(conf.user_arg, conf.group_arg);
if (conf.help_given || conf.detailed_help_given)
print_help_and_die();
+ drop_privileges_or_die(conf.user_arg, conf.group_arg);
parse_config_or_die();
daemon_set_flag(DF_LOG_TIME);
daemon_set_flag(DF_LOG_HOSTNAME);