ncurses/nc-cui: fix unreferenced assertion variable
authorBrett Grandbois <brett.grandbois@opengear.com>
Mon, 5 Feb 2018 20:40:30 +0000 (06:40 +1000)
committerSamuel Mendoza-Jonas <sam@mendozajonas.com>
Wed, 7 Feb 2018 21:01:38 +0000 (08:01 +1100)
Signed-off-by: Brett Grandbois <brett.grandbois@opengear.com>
Signed-off-by: Samuel Mendoza-Jonas <sam@mendozajonas.com>
ui/ncurses/nc-cui.c

index ee6df87b0c7d0a00f305a6460235d3b7215d93b3..372da1e7a13e154a3ba460e31a2691b8932fc746 100644 (file)
@@ -1574,7 +1574,8 @@ static void cui_cancel_autoboot_on_exit(struct cui *cui)
 
 int cui_run(struct cui *cui)
 {
 
 int cui_run(struct cui *cui)
 {
-       assert(main);
+       assert(cui);
+       assert(cui->main);
 
        cui->current = &cui->main->scr;
        cui->default_item = 0;
 
        cui->current = &cui->main->scr;
        cui->default_item = 0;