From: Jeremy Kerr Date: Thu, 1 May 2014 12:53:43 +0000 (+0800) Subject: discover,ui: fix checks for debug option X-Git-Tag: v1.0.0~181 X-Git-Url: https://git.ozlabs.org/?p=petitboot;a=commitdiff_plain;h=adb11b86f216f26c2301270af4f847f8d7429aef discover,ui: fix checks for debug option We need to check for equality with opt_yes, not just check for non-zero. Signed-off-by: Jeremy Kerr --- diff --git a/discover/pb-discover.c b/discover/pb-discover.c index e895f47..f876a3d 100644 --- a/discover/pb-discover.c +++ b/discover/pb-discover.c @@ -153,7 +153,7 @@ int main(int argc, char *argv[]) } pb_log_init(log); - if (opts.verbose) + if (opts.verbose == opt_yes) pb_log_set_debug(true); pb_log("--- pb-discover ---\n"); diff --git a/ui/ncurses/generic-main.c b/ui/ncurses/generic-main.c index 0d0a38a..fe288ee 100644 --- a/ui/ncurses/generic-main.c +++ b/ui/ncurses/generic-main.c @@ -311,7 +311,7 @@ int main(int argc, char *argv[]) pb_log_init(log); - if (opts.verbose) + if (opts.verbose == opt_yes) pb_log_set_debug(true); pb_log("--- petitboot-nc ---\n");