comparison src/eval.c @ 62980:5b94f4660d9d

(unbind_to): Preserve value of Vquit_flag.
author Kim F. Storm <storm@cua.dk>
date Fri, 03 Jun 2005 23:02:21 +0000
parents d66d7efe0adf
children 9bde03db5726 01137c1fdbe9
comparison
equal deleted inserted replaced
62979:c79b5010b654 62980:5b94f4660d9d
3128 Lisp_Object 3128 Lisp_Object
3129 unbind_to (count, value) 3129 unbind_to (count, value)
3130 int count; 3130 int count;
3131 Lisp_Object value; 3131 Lisp_Object value;
3132 { 3132 {
3133 int quitf = !NILP (Vquit_flag); 3133 Lisp_Object quitf = Vquit_flag;
3134 struct gcpro gcpro1; 3134 struct gcpro gcpro1, gcpro2;
3135 3135
3136 GCPRO1 (value); 3136 GCPRO2 (value, quitf);
3137 Vquit_flag = Qnil; 3137 Vquit_flag = Qnil;
3138 3138
3139 while (specpdl_ptr != specpdl + count) 3139 while (specpdl_ptr != specpdl + count)
3140 { 3140 {
3141 /* Copy the binding, and decrement specpdl_ptr, before we do 3141 /* Copy the binding, and decrement specpdl_ptr, before we do
3180 else 3180 else
3181 set_internal (this_binding.symbol, this_binding.old_value, 0, 1); 3181 set_internal (this_binding.symbol, this_binding.old_value, 0, 1);
3182 } 3182 }
3183 } 3183 }
3184 3184
3185 if (NILP (Vquit_flag) && quitf) 3185 if (NILP (Vquit_flag) && !NILP (quitf))
3186 Vquit_flag = Qt; 3186 Vquit_flag = quitf;
3187 3187
3188 UNGCPRO; 3188 UNGCPRO;
3189 return value; 3189 return value;
3190 } 3190 }
3191 3191