curses: Check if value is provided for ngraph

Fixes: CID 49001
Signed-off-by: Thomas Graf <tgraf@suug.ch>
This commit is contained in:
Thomas Graf 2014-08-24 20:48:12 +02:00
parent 22c83ceb1a
commit 3cff7715ce

View File

@ -1256,7 +1256,7 @@ static void curses_parse_opt(const char *type, const char *value)
c_graph_cfg.gc_height = strtol(value, NULL, 0);
else if (!strcasecmp(type, "gwidth") && value)
c_graph_cfg.gc_width = strtol(value, NULL, 0);
else if (!strcasecmp(type, "ngraph")) {
else if (!strcasecmp(type, "ngraph") && value) {
c_ngraph = strtol(value, NULL, 0);
c_show_graph = !!c_ngraph;
} else if (!strcasecmp(type, "details"))