From: Chong Yidong Date: Wed, 29 Oct 2008 18:22:12 +0000 (+0000) Subject: (bookmark-get-bookmark-record): Signal error for invalid bookmark. X-Git-Tag: emacs-pretest-23.0.90~2100 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=bdacf3958d1b9bfded926806c539a46aeab75e28;p=emacs.git (bookmark-get-bookmark-record): Signal error for invalid bookmark. --- diff --git a/lisp/bookmark.el b/lisp/bookmark.el index a6ebc99b6f7..07ec40ec827 100644 --- a/lisp/bookmark.el +++ b/lisp/bookmark.el @@ -330,7 +330,8 @@ Otherwise look for the corresponding bookmark in `bookmark-alist'." (defun bookmark-get-bookmark-record (bookmark) "Return the guts of the entry for BOOKMARK in `bookmark-alist'. That is, all information but the name." - (let ((alist (cdr (bookmark-get-bookmark bookmark)))) + (let ((alist (cdr (or (bookmark-get-bookmark bookmark) + (error "Invalid bookmark %s" bookmark))))) ;; The bookmark objects can either look like (NAME ALIST) or ;; (NAME . ALIST), so we have to distinguish the two here. (if (and (null (cdr alist)) (consp (caar alist)))