Browse Source

[mucurses] Avoid potential division by zero

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 6 years ago
parent
commit
c20da4fc5c
1 changed files with 1 additions and 2 deletions
  1. 1
    2
      src/hci/mucurses/slk.c

+ 1
- 2
src/hci/mucurses/slk.c View File

@@ -269,8 +269,7 @@ int slk_init ( int fmt ) {
269 269
 		slks->spaces[0] = 3; slks->spaces[1] = 7;
270 270
 		break;
271 271
 	default:
272
-		nblocks = 0; nmaj = 0; nmin = 0;
273
-		break;
272
+		return ERR;
274 273
 	}
275 274
 
276 275
 	// determine maximum label length and major space size

Loading…
Cancel
Save