diff options
Diffstat (limited to 'tty.c')
-rw-r--r-- | tty.c | 11 |
1 files changed, 5 insertions, 6 deletions
@@ -1,4 +1,4 @@ -/* $Id: tty.c,v 1.18 2008-01-02 19:22:21 nicm Exp $ */ +/* $Id: tty.c,v 1.19 2008-05-10 12:50:25 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -255,10 +255,6 @@ tty_find_term(char *name, int fd, char **cause) xasprintf(cause, "parm_ich missing"); goto error; } - if (parm_dch == NULL && delete_character == NULL) { - xasprintf(cause, "parm_dch missing"); - goto error; - } if (scroll_reverse == NULL) { xasprintf(cause, "scroll_reverse missing"); goto error; @@ -477,9 +473,12 @@ tty_vwrite(struct tty *tty, unused struct screen *s, int cmd, va_list ap) ua = va_arg(ap, u_int); if (parm_dch != NULL) tty_puts(tty, tparm(parm_dch, ua)); - else { + else if (delete_character != NULL) { while (ua-- > 0) tty_puts(tty, delete_character); + } else { + while (ua-- > 0) + tty_putc(tty, '\008'); } break; case TTY_CURSORON: |