$NetBSD: patch-aa,v 1.3 1999/05/22 21:41:44 tv Exp $ --- smallfn.c.orig Sat Apr 17 10:53:02 1999 +++ smallfn.c Sat May 22 17:38:30 1999 @@ -92,8 +92,12 @@ } if (Choice==4) { + char *s; mprintf(MAskNewName); - gets(Name); + *Name = '\0'; + fgets(Name, NM, stdin); + if ((s = strchr(Name, '\n')) != NULL) + *s = '\0'; continue; } if (Choice==5) @@ -110,7 +114,10 @@ int GetKey(void) { char Str[80]; - gets(Str); + *Str = '\0'; + fgets(Str, 80, stdin); + if (*Str == '\n') + *Str = '\0'; return(Str[0]); }