From 5abadebc353cdb55a162a7f35a299623537cd3a8 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Tue, 21 Jul 2015 19:09:12 -0400 Subject: [PATCH] (advice--called-interactively-skip): Fix inf-loop (bug#21083) * lisp/emacs-lisp/nadvice.el (advice--called-interactively-skip): Fix inf-loop (bug#21083). --- lisp/emacs-lisp/nadvice.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/emacs-lisp/nadvice.el b/lisp/emacs-lisp/nadvice.el index a6db5e9e696..5a59a980feb 100644 --- a/lisp/emacs-lisp/nadvice.el +++ b/lisp/emacs-lisp/nadvice.el @@ -522,8 +522,9 @@ of the piece of advice." (while (progn (funcall get-next-frame) - (not (and (eq (nth 1 frame2) 'apply) - (eq (nth 3 frame2) inneradvice))))) + (and frame2 + (not (and (eq (nth 1 frame2) 'apply) + (eq (nth 3 frame2) inneradvice)))))) (funcall get-next-frame) (funcall get-next-frame)))) (- i origi 1))))