branch: elpa/anzu
commit 380f5fd2329a333e5b4d3c91a78e7e41aba23284
Merge: 1eceed7498 3c178f75f3
Author: Syohei YOSHIDA <[email protected]>
Commit: Syohei YOSHIDA <[email protected]>

    Merge pull request #53 from kosh04/fix-literal-match
    
    Fix matching a literal string
---
 anzu.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/anzu.el b/anzu.el
index 4a3cae247a..010d96332c 100644
--- a/anzu.el
+++ b/anzu.el
@@ -557,7 +557,7 @@
 (defsubst anzu--replaced-literal-string (ov replaced from)
   (let ((str (buffer-substring-no-properties
               (overlay-start ov) (overlay-end ov))))
-    (when (string-match str from)
+    (when (string-match (regexp-quote str) from)
       (replace-match replaced (not case-fold-search) nil str))))
 
 (defun anzu--append-replaced-string (content buf beg end use-regexp 
overlay-limit from)

Reply via email to