]> git.eshelyaron.com Git - emacs.git/commitdiff
(double-setup): Only copy `key-translation-map' if it is a keymap.
authorRichard M. Stallman <rms@gnu.org>
Wed, 12 Aug 1998 19:45:38 +0000 (19:45 +0000)
committerRichard M. Stallman <rms@gnu.org>
Wed, 12 Aug 1998 19:45:38 +0000 (19:45 +0000)
lisp/double.el

index 8585f8716c80db0df9605b5a3d000782784bc1b3..7d318d9988a75049dc277d369e1ac9525ebbf045 100644 (file)
@@ -145,7 +145,9 @@ but not `C-u X' or `ESC X' since the X is not the prefix key."
        ;; Set up key-translation-map as indicated by `double-map'.
        (kill-local-variable 'key-translation-map)
        (make-local-variable 'key-translation-map)
-       (setq key-translation-map (copy-keymap key-translation-map))
+       (setq key-translation-map (if (keymapp key-translation-map)
+                                     (copy-keymap key-translation-map)
+                                   (make-sparse-keymap)))
        (mapcar (function (lambda (entry)
                            (define-key key-translation-map
                              (vector (nth 0 entry))