Mercurial > emacs
changeset 22309:41baef80bbbc
(Fredraw_frame): Don't erase frame or its glyph records
if it hasn't got any.
author | Karl Heuer <kwzh@gnu.org> |
---|---|
date | Mon, 01 Jun 1998 03:12:04 +0000 |
parents | 87366acfb1e9 |
children | c68a115303f7 |
files | src/dispnew.c |
diffstat | 1 files changed, 16 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/src/dispnew.c Mon Jun 01 03:09:43 1998 +0000 +++ b/src/dispnew.c Mon Jun 01 03:12:04 1998 +0000 @@ -178,13 +178,22 @@ CHECK_LIVE_FRAME (frame, 0); f = XFRAME (frame); - update_begin (f); - if (FRAME_MSDOS_P (f)) - set_terminal_modes (); - clear_frame (); - clear_frame_records (f); - update_end (f); - fflush (stdout); + + /* Erase the frame and its glyph records--if it has any records. + It may have none, in the case of the terminal frame + that initially exists but is never used + when Emacs is using a window system. */ + if (FRAME_CURRENT_GLYPHS (f) != 0) + { + update_begin (f); + if (FRAME_MSDOS_P (f)) + set_terminal_modes (); + clear_frame (); + clear_frame_records (f); + update_end (f); + fflush (stdout); + } + windows_or_buffers_changed++; /* Mark all windows as INaccurate, so that every window will have its redisplay done. */