]> git.eshelyaron.com Git - emacs.git/commitdiff
* progmodes/sh-script.el (sh-maybe-here-document): Avoid inserting
authorChong Yidong <cyd@stupidchicken.com>
Sun, 16 Aug 2009 14:04:25 +0000 (14:04 +0000)
committerChong Yidong <cyd@stupidchicken.com>
Sun, 16 Aug 2009 14:04:25 +0000 (14:04 +0000)
another heredoc if the user adds another < (Bug#3226).

lisp/ChangeLog
lisp/progmodes/sh-script.el

index 955521bb8a0437da91fff4da3d8683b1234590f7..2cdb28ddc3bc5b79b58af958a846bf8b17edb3de 100644 (file)
@@ -1,5 +1,8 @@
 2009-08-16  Chong Yidong  <cyd@stupidchicken.com>
 
+       * progmodes/sh-script.el (sh-maybe-here-document): Avoid inserting
+       another heredoc if the user adds another < (Bug#3226).
+
        * mwheel.el (mouse-wheel-down-event, mouse-wheel-up-event): Don't
        initialize based on window-system (Bug#4124).
 
index c5ca9bbd9c8aabd66f4d0333072961eb1aa915a0..d948f9f61f9822092d05f7775cadbb02bb883d88 100644 (file)
@@ -3749,7 +3749,7 @@ The document is bounded by `sh-here-document-word'."
   (interactive "*P")
   (self-insert-command (prefix-numeric-value arg))
   (or arg
-      (not (eq (char-after (- (point) 2)) last-command-event))
+      (not (looking-back "[^<]<<"))
       (save-excursion
        (backward-char 2)
        (sh-quoted-p))