Commit 44b16f60 authored by Eli Zaretskii's avatar Eli Zaretskii
Browse files

Avoid crashes in semi-malformed 'condition-case'

* src/eval.c (internal_lisp_condition_case): Treat a handler
'(nil)' as if it were '(nil nil)'.  (Bug#22675)
parent 652e5b49
......@@ -1245,7 +1245,7 @@ internal_lisp_condition_case (volatile Lisp_Object var, Lisp_Object bodyform,
for (i = 0; i < clausenb; i++)
{
Lisp_Object clause = clauses[i];
Lisp_Object condition = XCAR (clause);
Lisp_Object condition = CONSP (clause) ? XCAR (clause) : Qnil;
if (!CONSP (condition))
condition = Fcons (condition, Qnil);
struct handler *c = push_handler (condition, CONDITION_CASE);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment