Subject: bin/24642: sushi(8): f1 shows wrong message when there's no help available
To: None <gnats-bugs@gnats.NetBSD.org>
From: Peter Postma <peter@pointless.nl>
List: netbsd-bugs
Date: 03/02/2004 16:46:24
>Number:         24642
>Category:       bin
>Synopsis:       sushi(8): f1 shows wrong message when there's no help available
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    bin-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Mar 02 15:47:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator:     Peter Postma
>Release:        NetBSD 1.6ZK
>Organization:
>Environment:
System: NetBSD mercury.pointless.nl 1.6ZK NetBSD 1.6ZK (mercury) #25: Mon Feb 23 15:42:28 CET 2004 root@mercury.pointless.nl:/usr/obj/sys/arch/sparc64/compile/mercury sparc64
Architecture: sparc64
Machine: sparc64
>Description:
	When someone presses F1 (for help) and there's no help available
	then sushi says:

"The current field is a list field, and selections can only be made from"

>How-To-Repeat:
	Start sushi. Go to Security and Users.
	Press F1.
>Fix:

--- sushi-help.diff begins here ---
Index: C.msg
===================================================================
RCS file: /cvsroot/src/usr.sbin/sushi/C.msg,v
retrieving revision 1.9
diff -u -r1.9 C.msg
--- C.msg	15 Mar 2001 09:10:31 -0000	1.9
+++ C.msg	2 Mar 2004 15:39:57 -0000
@@ -54,6 +54,7 @@
 13 The current field is a multiple-selection list field.  The field can only
 14 be edited by issuing the List(F4) command, and toggling desired options
 15 with the spacebar.  Press the ENTER key to return from the list popup.
+16 No help is available for this screen.
 $set 4 menu titles and stuff
 1 Select choice
 2 Generating form data, please wait
Index: handlers.c
===================================================================
RCS file: /cvsroot/src/usr.sbin/sushi/handlers.c,v
retrieving revision 1.5
diff -u -r1.5 handlers.c
--- handlers.c	12 Nov 2003 13:31:08 -0000	1.5
+++ handlers.c	2 Mar 2004 15:39:57 -0000
@@ -267,9 +267,9 @@
 void
 nohelp(void)
 {
-	char *mesg[2];
+	char *mesg[1];
 
-	mesg[0] = catgets(catalog, 3, 10,
+	mesg[0] = catgets(catalog, 3, 16,
 	    "No help is available for this screen.");
 	popupLabel(cdkscreen, mesg, 1);
 }
--- sushi-help.diff ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted: