summaryrefslogtreecommitdiff
path: root/usr.bin
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/mg/re_search.c5
-rw-r--r--usr.bin/mg/region.c6
-rw-r--r--usr.bin/mg/search.c5
3 files changed, 9 insertions, 7 deletions
diff --git a/usr.bin/mg/re_search.c b/usr.bin/mg/re_search.c
index b89f4500816..3aa91b89d21 100644
--- a/usr.bin/mg/re_search.c
+++ b/usr.bin/mg/re_search.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: re_search.c,v 1.14 2005/04/03 02:09:28 db Exp $ */
+/* $OpenBSD: re_search.c,v 1.15 2005/06/05 05:15:56 kjell Exp $ */
/*
* regular expression search commands for Mg
@@ -414,7 +414,8 @@ re_readpattern(char *prompt)
if (re_pat[0] == '\0')
rep = ereply("%s: ", tpat, NPAT, prompt);
else
- rep = ereply("%s: (default %s) ", tpat, NPAT, prompt, re_pat);
+ rep = eread("%s: (default %s) ", tpat, NPAT,
+ EFNUL | EFNEW | EFCR, prompt, re_pat);
if (rep != NULL && *rep != '\0') {
/* New pattern given */
diff --git a/usr.bin/mg/region.c b/usr.bin/mg/region.c
index 54e628a6e65..dd9c31fe687 100644
--- a/usr.bin/mg/region.c
+++ b/usr.bin/mg/region.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: region.c,v 1.15 2005/04/03 02:09:28 db Exp $ */
+/* $OpenBSD: region.c,v 1.16 2005/06/05 05:15:56 kjell Exp $ */
/*
* Region based commands.
@@ -305,8 +305,8 @@ setprefix(int f, int n)
if (prefix_string[0] == '\0')
rep = ereply("Prefix string: ", buf, sizeof(buf));
else
- rep = ereply("Prefix string (default %s): ",
- buf, sizeof(buf), prefix_string);
+ rep = eread("Prefix string (default %s): ",
+ buf, sizeof(buf), EFNUL | EFNEW | EFCR, prefix_string);
if (rep != NULL && *rep != '\0') {
(void)strlcpy(prefix_string, rep, sizeof(prefix_string));
retval = TRUE;
diff --git a/usr.bin/mg/search.c b/usr.bin/mg/search.c
index a6d88e4206d..70c31df5e85 100644
--- a/usr.bin/mg/search.c
+++ b/usr.bin/mg/search.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: search.c,v 1.18 2005/06/03 15:16:22 cloder Exp $ */
+/* $OpenBSD: search.c,v 1.19 2005/06/05 05:15:56 kjell Exp $ */
/*
* Search commands.
@@ -775,7 +775,8 @@ readpattern(char *prompt)
if (pat[0] == '\0')
rep = ereply("%s: ", tpat, NPAT, prompt);
else
- rep = ereply("%s: (default %s) ", tpat, NPAT, prompt, pat);
+ rep = eread("%s: (default %s) ", tpat, NPAT,
+ EFNUL | EFNEW | EFCR, prompt, pat);
/* specified */
if (rep == NULL) {