From 329ce860561be22f8087bc421c623946df9be9f4 Mon Sep 17 00:00:00 2001 From: "nethack.rankin" Date: Thu, 10 Oct 2002 23:16:02 +0000 Subject: [PATCH] different extended command bit (tty) I've found myself adding a trailing space to various extend commands from time to time, and the program fails to recognize then when that happens. It might be less likely once none of them has any embedded spaces, but this wouldn't hurt anything if that becomes the case. --- win/tty/getline.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/win/tty/getline.c b/win/tty/getline.c index afeeeaabc..7dd3dbf3b 100644 --- a/win/tty/getline.c +++ b/win/tty/getline.c @@ -1,4 +1,4 @@ -/* SCCS Id: @(#)getline.c 3.4 1996/01/27 */ +/* SCCS Id: @(#)getline.c 3.4 2002/10/06 */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /* NetHack may be freely redistributed. See license for details. */ @@ -214,6 +214,7 @@ tty_get_ext_cmd() #else hooked_tty_getlin("#", buf, ext_cmd_getlin_hook); #endif + (void) mungspaces(buf); if (buf[0] == 0 || buf[0] == '\033') return -1; for (i = 0; extcmdlist[i].ef_txt != (char *)0; i++) -- 2.40.0