summaryrefslogtreecommitdiff
path: root/usr.bin/talk/display.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin/talk/display.c')
-rw-r--r--usr.bin/talk/display.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/usr.bin/talk/display.c b/usr.bin/talk/display.c
index 7bdf38ea8c84..789467ee0271 100644
--- a/usr.bin/talk/display.c
+++ b/usr.bin/talk/display.c
@@ -85,6 +85,18 @@ display(win, text, size)
text++;
continue;
}
+ if (*text == 004 && win == &my_win) {
+ /* control-D clears the screen */
+ werase(my_win.x_win);
+ getyx(my_win.x_win, my_win.x_line, my_win.x_col);
+ wrefresh(my_win.x_win);
+ werase(his_win.x_win);
+ getyx(his_win.x_win, his_win.x_line, his_win.x_col);
+ wrefresh(his_win.x_win);
+ text++;
+ continue;
+ }
+
/* erase character */
if ( *text == win->cerase
|| *text == 010 /* BS */