diff --git a/sys/arch/hpcmips/dev/bicons.c b/sys/arch/hpcmips/dev/bicons.c index 97d3af05feb2..7aefd3d401c4 100644 --- a/sys/arch/hpcmips/dev/bicons.c +++ b/sys/arch/hpcmips/dev/bicons.c @@ -1,4 +1,4 @@ -/* $NetBSD: bicons.c,v 1.1.1.1 1999/09/16 12:23:19 takemura Exp $ */ +/* $NetBSD: bicons.c,v 1.2 1999/11/02 10:33:05 takemura Exp $ */ /*- * Copyright (c) 1999 @@ -38,11 +38,13 @@ #include #include +#include #include #include #include #include +#include #include #include @@ -206,6 +208,23 @@ bicons_putn(char *s, int n) } } +void +#ifdef __STDC__ +bicons_printf(const char *fmt, ...) +#else +bicons_printf(fmt, va_alist) + char *fmt; + va_dcl +#endif +{ + va_list ap; + char buf[1000]; + + va_start(ap, fmt); + vsnprintf(buf, sizeof(buf), fmt, ap); + va_end(ap); + bicons_puts(buf); +} int bicons_getc(dev_t dev) @@ -223,9 +242,10 @@ bicons_putc(dev_t dev, int c) switch (c) { case 0x08: /* back space */ if (--curs_x < 0) { - /* erase character ar cursor position */ - draw_char(curs_x, curs_y, ' '); + curs_x = 0; } + /* erase character ar cursor position */ + draw_char(curs_x, curs_y, ' '); break; case '\r': curs_x = 0; diff --git a/sys/arch/hpcmips/dev/bicons.h b/sys/arch/hpcmips/dev/bicons.h index 8c0f76286fce..e0e5f41cd031 100644 --- a/sys/arch/hpcmips/dev/bicons.h +++ b/sys/arch/hpcmips/dev/bicons.h @@ -1,4 +1,4 @@ -/* $NetBSD: bicons.h,v 1.1.1.1 1999/09/16 12:23:19 takemura Exp $ */ +/* $NetBSD: bicons.h,v 1.2 1999/11/02 10:33:05 takemura Exp $ */ /*- * Copyright (c) 1999 @@ -37,3 +37,4 @@ void bicons_init __P((void)); void bicons_puts __P((char *s)); void bicons_putn __P((char *s, int n)); +void bicons_printf __P((const char *, ...));