From: Eric Abrahamsen Date: Mon, 8 Feb 2021 20:27:04 +0000 (-0800) Subject: Run Gnus group names through regexp-quote when matching results X-Git-Tag: emacs-28.0.90~3866 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=1b0e6a16d3ae32576a642898c39695a3affd2fd7;p=emacs.git Run Gnus group names through regexp-quote when matching results * lisp/gnus/gnus-search.el (gnus-search-indexed-parse-output): Be more careful about making sure group names will match search results correctly. --- diff --git a/lisp/gnus/gnus-search.el b/lisp/gnus/gnus-search.el index 4538370584b..d7b1c06114b 100644 --- a/lisp/gnus/gnus-search.el +++ b/lisp/gnus/gnus-search.el @@ -1348,12 +1348,14 @@ Returns a list of [group article score] vectors." (let ((prefix (slot-value engine 'remove-prefix)) (group-regexp (when groups (mapconcat - (lambda (x) - (replace-regexp-in-string - ;; Accept any of [.\/] as path separators. - "[.\\/]" "[.\\\\/]" - (gnus-group-real-name x))) - groups "\\|"))) + (lambda (group-name) + (mapconcat #'regexp-quote + (split-string + (gnus-group-real-name group-name) + "[.\\/]") + "[.\\\\/]")) + groups + "\\|"))) artlist vectors article group) (goto-char (point-min)) (while (not (eobp))