Avoid signaling errors in 'cursor-face-highlight-mode'

* lisp/simple.el (redisplay--update-cursor-face-highlight): Don't
go beyond the accessible portion of the buffer.  (Bug#77747)
This commit is contained in:
Eli Zaretskii 2025-04-26 17:20:01 +03:00
parent ec8075219d
commit f7aad714d2

View file

@ -7265,7 +7265,7 @@ This variable is similar to `highlight-nonselected-windows'."
(pt (window-point window))
(cursor-face (get-text-property pt 'cursor-face)))
(let* ((start (previous-single-property-change
(1+ pt) 'cursor-face nil (point-min)))
(min (1+ pt) (point-max)) 'cursor-face nil (point-min)))
(end (next-single-property-change
pt 'cursor-face nil (point-max)))
(new (redisplay--highlight-overlay-function