1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-29 08:31:35 -08:00

Fix assertions in nth_minibuffer

* src/minibuf.c (nth_minibuffer): Avoid assertion violation when
DEPTHth minibuffer doesn't exist.  (Bug#48337)
This commit is contained in:
Eli Zaretskii 2021-05-11 16:37:37 +03:00
parent 2db8a3257c
commit c9bf4e7f43

View file

@ -969,6 +969,8 @@ static Lisp_Object
nth_minibuffer (EMACS_INT depth)
{
Lisp_Object tail = Fnthcdr (make_fixnum (depth), Vminibuffer_list);
if (NILP (tail))
return Qnil;
return XCAR (tail);
}