summaryrefslogtreecommitdiffstats
path: root/sys/kern
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>2013-12-31 04:40:25 +0000
committerimp <imp@FreeBSD.org>2013-12-31 04:40:25 +0000
commit8b020609303063ce0cd3a62b5b289e501f1deace (patch)
tree16c2b05b77db9465cfa698b754931ab3f3c28127 /sys/kern
parentee6c4eb4c8f5aad16ffd69ac07c776e8e958289f (diff)
downloadFreeBSD-src-8b020609303063ce0cd3a62b5b289e501f1deace.zip
FreeBSD-src-8b020609303063ce0cd3a62b5b289e501f1deace.tar.gz
Delete echoed doesn't rub out the previous character, so always
use <backspace> <space> <backspace> instead. This fixes hitting DELETE instead of BACKSPACE at mountroot> prompt.
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/kern_cons.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/kern/kern_cons.c b/sys/kern/kern_cons.c
index d17846a..72b384f 100644
--- a/sys/kern/kern_cons.c
+++ b/sys/kern/kern_cons.c
@@ -432,10 +432,8 @@ cngets(char *cp, size_t size, int visible)
case '\b':
case '\177':
if (lp > cp) {
- if (visible) {
- cnputc(c);
- cnputs(" \b");
- }
+ if (visible)
+ cnputs("\b \b");
lp--;
}
continue;
OpenPOWER on IntegriCloud