* lisp/emacs-lisp/edebug.el (edebug-instrument-function): Check a marker is

still valid before using it.
This commit is contained in:
Stefan Monnier 2011-02-10 14:21:07 -05:00
parent 1a0a6cefcf
commit 49ffc0786e
2 changed files with 4 additions and 1 deletions

View file

@ -3394,7 +3394,7 @@ go to the end of the last sexp, or if that is the same point, then step."
;; Return the function symbol, or nil if not instrumented.
(let ((func-marker (get func 'edebug)))
(cond
((markerp func-marker)
((and (markerp func-marker) (marker-buffer func-marker))
;; It is uninstrumented, so instrument it.
(with-current-buffer (marker-buffer func-marker)
(goto-char func-marker)