diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/dispnew.c | 14 | ||||
| -rw-r--r-- | src/xdisp.c | 2 |
2 files changed, 14 insertions, 2 deletions
diff --git a/src/dispnew.c b/src/dispnew.c index 4cf131522ec..4dd5ee2a1e0 100644 --- a/src/dispnew.c +++ b/src/dispnew.c | |||
| @@ -2051,7 +2051,19 @@ adjust_frame_glyphs_for_frame_redisplay (struct frame *f) | |||
| 2051 | to the frame width (from CHANGE_FRAME_SIZE_1). */ | 2051 | to the frame width (from CHANGE_FRAME_SIZE_1). */ |
| 2052 | if (matrix_dim.width != FRAME_TOTAL_COLS (f) | 2052 | if (matrix_dim.width != FRAME_TOTAL_COLS (f) |
| 2053 | || matrix_dim.height != FRAME_TOTAL_LINES (f)) | 2053 | || matrix_dim.height != FRAME_TOTAL_LINES (f)) |
| 2054 | return; | 2054 | { |
| 2055 | /* We have reallocated the frame's glyph pools, but didn't | ||
| 2056 | update the glyph pointers in the frame's glyph matrices | ||
| 2057 | to use the reallocated pools (that happens below, in the | ||
| 2058 | call to adjust_glyph_matrix). Set the frame's garbaged | ||
| 2059 | flag, so that when we are called again from | ||
| 2060 | redisplay_internal, we don't erroneously call | ||
| 2061 | save_current_matrix, because it will use the wrong glyph | ||
| 2062 | pointers, and will most probably crash. */ | ||
| 2063 | if (!FRAME_WINDOW_P (f) && pool_changed_p) | ||
| 2064 | SET_FRAME_GARBAGED (f); | ||
| 2065 | return; | ||
| 2066 | } | ||
| 2055 | 2067 | ||
| 2056 | eassert (matrix_dim.width == FRAME_TOTAL_COLS (f) | 2068 | eassert (matrix_dim.width == FRAME_TOTAL_COLS (f) |
| 2057 | && matrix_dim.height == FRAME_TOTAL_LINES (f)); | 2069 | && matrix_dim.height == FRAME_TOTAL_LINES (f)); |
diff --git a/src/xdisp.c b/src/xdisp.c index 29d49d57dfd..1586a02e3d4 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -15684,7 +15684,7 @@ redisplay_internal (void) | |||
| 15684 | the frame. Don't do that on TTY frames, since we | 15684 | the frame. Don't do that on TTY frames, since we |
| 15685 | need to keep the garbaged flag in that case when | 15685 | need to keep the garbaged flag in that case when |
| 15686 | the frame has been resized. */ | 15686 | the frame has been resized. */ |
| 15687 | if (FRAME_WINDOW_P (f) && FRAME_GARBAGED_P (f)) | 15687 | if (FRAME_GARBAGED_P (f)) |
| 15688 | { | 15688 | { |
| 15689 | fset_redisplay (f); | 15689 | fset_redisplay (f); |
| 15690 | f->garbaged = false; | 15690 | f->garbaged = false; |