diff options
author | Hans Dedecker <dedeckeh@gmail.com> | 2017-02-13 09:29:12 +0100 |
---|---|---|
committer | Hans Dedecker <dedeckeh@gmail.com> | 2017-02-13 09:40:37 +0100 |
commit | 51c756cfc15c63322df9fdb70d5c701cfb6b9a9f (patch) | |
tree | eefe419dc38472fa5237bb23916fbcc9815870f6 /src/odhcpd.c | |
parent | 68ee0b59040625d2ab5830b1c1cc8eca2da0dcf1 (diff) |
odhcpd: display correct default log level in usage text
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
Diffstat (limited to 'src/odhcpd.c')
-rw-r--r-- | src/odhcpd.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/odhcpd.c b/src/odhcpd.c index ed96178..9a76e4d 100644 --- a/src/odhcpd.c +++ b/src/odhcpd.c @@ -52,7 +52,7 @@ static int ioctl_sock; static struct nl_sock *rtnl_socket = NULL; static int urandom_fd = -1; - +static int log_level = LOG_INFO; static void sighandler(_unused int signal) { @@ -65,7 +65,7 @@ static void print_usage(const char *app) "== %s Usage ==\n\n" " -h, --help Print this help\n" " -l level Specify log level 0..7 (default %d)\n", - app, LOG_WARNING + app, log_level ); } @@ -73,7 +73,7 @@ int main(int argc, char **argv) { openlog("odhcpd", LOG_PERROR | LOG_PID, LOG_DAEMON); int opt; - int log_level = LOG_INFO; + while ((opt = getopt(argc, argv, "hl:")) != -1) { switch (opt) { case 'h': |