From 5b817cf26eaba0b97509bdf3aad78343209190e0 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Wed, 2 Feb 1994 18:46:29 +0000 Subject: [PATCH] (disable-command): Reject invalid commands. --- lisp/novice.el | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lisp/novice.el b/lisp/novice.el index 2353edc5719..972d0737649 100644 --- a/lisp/novice.el +++ b/lisp/novice.el @@ -108,6 +108,8 @@ to future sessions." The user's .emacs file is altered so that this will apply to future sessions." (interactive "CDisable command: ") + (if (not (commandp command)) + (error "Invalid command name `%s'" command)) (put command 'disabled t) (save-excursion (set-buffer (find-file-noselect -- 2.39.5