diff lisp/tmm.el @ 13581:e69e87bdc813

(tmm-prompt): Delete tmm-add-prompt if we fail. Don't switch to *Completions* if it wasn't created.
author Richard M. Stallman <rms@gnu.org>
date Sat, 18 Nov 1995 15:57:50 +0000
parents d081e1969406
children 1319e4b9aa6c
line wrap: on
line diff
--- a/lisp/tmm.el	Sat Nov 18 15:50:42 1995 +0000
+++ b/lisp/tmm.el	Sat Nov 18 15:57:50 1995 +0000
@@ -115,9 +115,12 @@
 		      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)