From: Juanma Barranquero Date: Wed, 28 Feb 2007 12:50:43 +0000 (+0000) Subject: (where-is): Fail gracefully when not passed a command. X-Git-Tag: emacs-pretest-22.0.95~32 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=463d75acd952150ac6b78efb6d8e320d5f447b00;p=emacs.git (where-is): Fail gracefully when not passed a command. --- diff --git a/lisp/help.el b/lisp/help.el index 8aa9ba6c46b..d0783dd0351 100644 --- a/lisp/help.el +++ b/lisp/help.el @@ -491,6 +491,7 @@ If INSERT (the prefix arg) is non-nil, insert the message in the buffer." "Where is command: ") obarray 'commandp t)) (list (if (equal val "") fn (intern val)) current-prefix-arg))) + (unless definition (error "No command")) (let ((func (indirect-function definition)) (defs nil) (standard-output (if insert (current-buffer) t)))