From: Richard M. Stallman Date: Sat, 18 Nov 1995 15:57:50 +0000 (+0000) Subject: (tmm-prompt): Delete tmm-add-prompt if we fail. X-Git-Tag: emacs-19.34~2279 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c5c4b51cc68d84b6cf3db933ac595c95e54de104;p=emacs.git (tmm-prompt): Delete tmm-add-prompt if we fail. Don't switch to *Completions* if it wasn't created. --- diff --git a/lisp/tmm.el b/lisp/tmm.el index 281b6a3d845..1d23ffb5ca9 100644 --- a/lisp/tmm.el +++ b/lisp/tmm.el @@ -115,9 +115,12 @@ If the optional argument IN-POPUP is set, is argument-compatible with tmm-km-list nil t nil (cons 'history (* 2 history-len)))) (save-excursion - (set-buffer "*Completions*") - (use-local-map tmm-old-comp-map) - (bury-buffer (current-buffer))) + (remove-hook 'minibuffer-setup-hook 'tmm-add-prompt) + (if (get-buffer "*Completions*") + (progn + (set-buffer "*Completions*") + (use-local-map tmm-old-comp-map) + (bury-buffer (current-buffer))))) ))) (setq bind (cdr (assoc out tmm-km-list))) (and (null bind)