diff options
| author | Eli Zaretskii | 2024-06-03 21:13:05 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2024-06-03 21:13:05 +0300 |
| commit | 642bf58d4fbff4493b629837564b7e5c77c7615c (patch) | |
| tree | 274dfd3f988187f844a774a3ba92ea2ac1d60c3c /src | |
| parent | 16fc5b6c0c72464a75d9a84b754375662b3acec6 (diff) | |
| download | emacs-642bf58d4fbff4493b629837564b7e5c77c7615c.tar.gz emacs-642bf58d4fbff4493b629837564b7e5c77c7615c.zip | |
Avoid assertion violations in 'try_window_id'
* src/xdisp.c (try_window_id): Avoid assertions in
'find_first_unchanged_at_end_row' due to 'init_iterator' freeing
all the realized faces. (Bug#71274)
Diffstat (limited to 'src')
| -rw-r--r-- | src/xdisp.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/xdisp.c b/src/xdisp.c index 47675fcc80a..3d8651f4086 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -22337,6 +22337,13 @@ try_window_id (struct window *w) | |||
| 22337 | start_pos = it.current.pos; | 22337 | start_pos = it.current.pos; |
| 22338 | } | 22338 | } |
| 22339 | 22339 | ||
| 22340 | /* init_to_row_end and start_display above could have caused the | ||
| 22341 | window's window_end_valid flag to be reset (e.g., if init_iterator | ||
| 22342 | decides to free all realized faces). We cannot continue if that | ||
| 22343 | happens. */ | ||
| 22344 | if (!w->window_end_valid) | ||
| 22345 | GIVE_UP (108); | ||
| 22346 | |||
| 22340 | /* Find the first row that is not affected by changes at the end of | 22347 | /* Find the first row that is not affected by changes at the end of |
| 22341 | the buffer. Value will be null if there is no unchanged row, in | 22348 | the buffer. Value will be null if there is no unchanged row, in |
| 22342 | which case we must redisplay to the end of the window. delta | 22349 | which case we must redisplay to the end of the window. delta |