]> code.delx.au - gnu-emacs/commitdiff
pcmpl-ssh-known-hosts: Use `char-before' instead of `looking-back'.
authorNicolas Richard <theonewiththeevillook@yahoo.fr>
Fri, 3 Apr 2015 10:28:40 +0000 (12:28 +0200)
committerNicolas Richard <theonewiththeevillook@yahoo.fr>
Fri, 3 Apr 2015 11:57:42 +0000 (13:57 +0200)
Fixes: debbugs:17284
* lisp/pcmpl-unix.el (pcmpl-ssh-known-hosts): Use `char-before' instead
of `looking-back'.

lisp/ChangeLog
lisp/pcmpl-unix.el

index b004a2bba966b1012140cae27247f55081747947..7a4293b16ef2bf9474b5116af48137796f46030f 100644 (file)
@@ -1,3 +1,8 @@
+2015-04-03  Nicolas Richard  <theonewiththeevillook@yahoo.fr>
+
+       * pcmpl-unix.el (pcmpl-ssh-known-hosts): Use `char-before' instead
+       of `looking-back' (bug#17284).
+
 2015-04-03  Dmitry Gutov  <dgutov@yandex.ru>
 
        * progmodes/js.el (js-indent-line): Do nothing when bol is inside
index 3598cd64b461245e9883ab540e7fe3a21539e262..7be57e9c93acc8897e202e388753cade0b11fe39 100644 (file)
@@ -157,7 +157,7 @@ documentation), this function returns nil."
         (while (re-search-forward (concat "^ *" host-re) nil t)
           (add-to-list 'ssh-hosts-list (concat (match-string 1)
                                                (match-string 2)))
-          (while (and (looking-back ",")
+          (while (and (eq (char-before) ?,)
                       (re-search-forward host-re (line-end-position) t))
             (add-to-list 'ssh-hosts-list (concat (match-string 1)
                                                  (match-string 2)))))