summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/arch/pica/pica/swapgeneric.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/sys/arch/pica/pica/swapgeneric.c b/sys/arch/pica/pica/swapgeneric.c
index 29fc7a8eb90..303b5e5f542 100644
--- a/sys/arch/pica/pica/swapgeneric.c
+++ b/sys/arch/pica/pica/swapgeneric.c
@@ -160,30 +160,34 @@ gets(cp)
lp = cp;
for (;;) {
- printf("%c", c = cngetc()&0177);
+ c = cngetc() & 0177;
switch (c) {
case '\n':
case '\r':
+ cnputc(c);
*lp++ = '\0';
return;
case '\b':
case '\177':
if (lp > cp) {
- printf(" \b");
+ printf("\b \b");
lp--;
}
continue;
case '#':
+ cnputc(c);
lp--;
if (lp < cp)
lp = cp;
continue;
case '@':
case 'u'&037:
+ cnputc(c);
+ cnputc('\n');
lp = cp;
- printf("%c", '\n');
continue;
default:
+ cnputc(c);
*lp++ = c;
}
}