summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2014-05-01 20:53:43 +0800
committerJeremy Kerr <jk@ozlabs.org>2014-05-01 20:56:04 +0800
commitadb11b86f216f26c2301270af4f847f8d7429aef (patch)
tree994f884b319f4c808e3ea7080cdff490f8dda0e7
parent4caf65688fd16934235139cfa5e885a62f8f7370 (diff)
downloadtalos-petitboot-adb11b86f216f26c2301270af4f847f8d7429aef.tar.gz
talos-petitboot-adb11b86f216f26c2301270af4f847f8d7429aef.zip
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 <jk@ozlabs.org>
-rw-r--r--discover/pb-discover.c2
-rw-r--r--ui/ncurses/generic-main.c2
2 files changed, 2 insertions, 2 deletions
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");
OpenPOWER on IntegriCloud