diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/dispnew.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/dispnew.c b/src/dispnew.c index 90d9fc2fc55..0301c57cb19 100644 --- a/src/dispnew.c +++ b/src/dispnew.c | |||
| @@ -2549,6 +2549,22 @@ For types not defined in VMS, use define emacs_term \"TYPE\".\n\ | |||
| 2549 | 2549 | ||
| 2550 | term_init (terminal_type); | 2550 | term_init (terminal_type); |
| 2551 | 2551 | ||
| 2552 | { | ||
| 2553 | int width = FRAME_WINDOW_WIDTH (selected_frame); | ||
| 2554 | int height = FRAME_HEIGHT (selected_frame); | ||
| 2555 | |||
| 2556 | unsigned int total_glyphs = height * (width + 2) * sizeof (GLYPH); | ||
| 2557 | |||
| 2558 | /* If these sizes are so big they cause overflow, | ||
| 2559 | just ignore the change. It's not clear what better we could do. */ | ||
| 2560 | if (total_glyphs / sizeof (GLYPH) / height != width + 2) | ||
| 2561 | { | ||
| 2562 | fprintf (stderr, "emacs: screen size %dx%d too big\n,", | ||
| 2563 | width, height); | ||
| 2564 | exit (1); | ||
| 2565 | } | ||
| 2566 | } | ||
| 2567 | |||
| 2552 | remake_frame_glyphs (selected_frame); | 2568 | remake_frame_glyphs (selected_frame); |
| 2553 | calculate_costs (selected_frame); | 2569 | calculate_costs (selected_frame); |
| 2554 | 2570 | ||