Skip to content

Commit 7cb5364

Browse files
committed
Check if mouse_face_overlay was deleted (Bug#35273)
* src/xdisp.c (note_mouse_highlight): Check if the mouse_face_overlay actually points to a buffer, before calling mouse_face_overlay_overlaps on it.
1 parent 531c74e commit 7cb5364

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/xdisp.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31526,7 +31526,9 @@ note_mouse_highlight (struct frame *f, int x, int y)
3152631526
is currently hidden to avoid Bug#30519. */
3152731527
|| (!hlinfo->mouse_face_hidden
3152831528
&& OVERLAYP (hlinfo->mouse_face_overlay)
31529-
&& mouse_face_overlay_overlaps (hlinfo->mouse_face_overlay)))
31529+
/* It's possible the overlay was deleted (Bug#35273). */
31530+
&& XMARKER (OVERLAY_START (hlinfo->mouse_face_overlay))->buffer
31531+
&& mouse_face_overlay_overlaps (hlinfo->mouse_face_overlay)))
3153031532
{
3153131533
/* Find the highest priority overlay with a mouse-face. */
3153231534
Lisp_Object overlay = Qnil;

0 commit comments

Comments
 (0)