From 73ffa92b1818940f4f40805def559ed5c91468ed Mon Sep 17 00:00:00 2001 From: garbled Date: Mon, 22 Jan 2001 07:12:49 +0000 Subject: [PATCH] Fix one of the bugs in the TODO list, sushi would die with a bad endpoint if you hit enter on one of the blank lines in the main menu. --- usr.sbin/sushi/TODO | 1 - usr.sbin/sushi/sushi.c | 9 ++++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/usr.sbin/sushi/TODO b/usr.sbin/sushi/TODO index 58f322874581..b8567092ff60 100644 --- a/usr.sbin/sushi/TODO +++ b/usr.sbin/sushi/TODO @@ -1,7 +1,6 @@ ? abort key for run Make F6 work commmandline switches for log/script - enter on a BLANK entry makes sushi die with bad endpoint Something should indicate when scripting is on. bottom menu. F8 Image -> Screenshot diff --git a/usr.sbin/sushi/sushi.c b/usr.sbin/sushi/sushi.c index 556c5e82e9c3..76a6380273f9 100644 --- a/usr.sbin/sushi/sushi.c +++ b/usr.sbin/sushi/sushi.c @@ -1,4 +1,4 @@ -/* $NetBSD: sushi.c,v 1.7 2001/01/14 21:23:23 garbled Exp $ */ +/* $NetBSD: sushi.c,v 1.8 2001/01/22 07:12:49 garbled Exp $ */ /* * Copyright (c) 2000 The NetBSD Foundation, Inc. @@ -357,16 +357,19 @@ display_menu(cqm, title, basedir) bind_menu(scrollp, basedir); +loop: selection = activateCDKScroll(scrollp, NULL); + mte = tree_getentry(cqm, selection); + if (selection != -1 && strcmp(mte->filename, "BLANK") == 0) + goto loop; + destroyCDKScroll(scrollp); for(i=0; i