aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/gnus/ChangeLog3
-rw-r--r--lisp/gnus/gnus.el13
2 files changed, 10 insertions, 6 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog
index 5867a5c0bc9..8859ce8c4ad 100644
--- a/lisp/gnus/ChangeLog
+++ b/lisp/gnus/ChangeLog
@@ -81,6 +81,9 @@
81 81
822010-10-06 Julien Danjou <julien@danjou.info> 822010-10-06 Julien Danjou <julien@danjou.info>
83 83
84 * gnus.el (gnus-expand-group-parameter): Only return and act on what
85 was matched.
86
84 * sieve-manage.el: Update example in `Commentary'. 87 * sieve-manage.el: Update example in `Commentary'.
85 88
86 * sieve.el (sieve-open-server): Use sieve-manage-authenticate. 89 * sieve.el (sieve-open-server): Use sieve-manage-authenticate.
diff --git a/lisp/gnus/gnus.el b/lisp/gnus/gnus.el
index 12215dee702..b62bf051c5d 100644
--- a/lisp/gnus/gnus.el
+++ b/lisp/gnus/gnus.el
@@ -3815,12 +3815,13 @@ You should probably use `gnus-find-method-for-group' instead."
3815 3815
3816(defun gnus-expand-group-parameter (match value group) 3816(defun gnus-expand-group-parameter (match value group)
3817 "Use MATCH to expand VALUE in GROUP." 3817 "Use MATCH to expand VALUE in GROUP."
3818 (with-temp-buffer 3818 (let ((start (string-match match group)))
3819 (insert group) 3819 (if start
3820 (goto-char (point-min)) 3820 (let ((matched-string (substring group start (match-end 0))))
3821 (while (re-search-forward match nil t) 3821 ;; Build match groups
3822 (replace-match value)) 3822 (string-match match matched-string)
3823 (buffer-string))) 3823 (replace-match value nil nil matched-string))
3824 group)))
3824 3825
3825(defun gnus-expand-group-parameters (match parameters group) 3826(defun gnus-expand-group-parameters (match parameters group)
3826 "Go through PARAMETERS and expand them according to the match data." 3827 "Go through PARAMETERS and expand them according to the match data."