aboutsummaryrefslogtreecommitdiff
path: root/piem-gnus.el
diff options
context:
space:
mode:
authorKyle Meyer <kyle@kyleam.com>2021-01-03 06:34:39 +0000
committerKyle Meyer <kyle@kyleam.com>2021-01-03 12:49:32 -0500
commit96da1c622caac904e3f60e306847a4e68ca15e0c (patch)
tree103949a770baf4a772f27976d68080c92415f629 /piem-gnus.el
parent9f574d91248c36f22f3ca95cfca6d5bb724007dd (diff)
downloadpiem-96da1c622caac904e3f60e306847a4e68ca15e0c.tar.gz
Decode more message headers
piem-extract-mbox-info feeds the "from" header value through rfc2047-decode-string, but the same treatment should be applied to other header values. Message-Id: <20210103063425.22718-1-kyle@kyleam.com>
Diffstat (limited to 'piem-gnus.el')
-rw-r--r--piem-gnus.el7
1 files changed, 5 insertions, 2 deletions
diff --git a/piem-gnus.el b/piem-gnus.el
index dd0234c..c6b9d0c 100644
--- a/piem-gnus.el
+++ b/piem-gnus.el
@@ -31,6 +31,7 @@
(require 'gnus-sum)
(require 'message)
(require 'piem)
+(require 'rfc2047)
(defgroup piem-gnus nil
"Gnus integration for piem."
@@ -85,8 +86,10 @@ message itself if it looks like a patch."
(when-let ((patch (with-current-buffer gnus-article-buffer
(save-restriction
(widen)
- (and (string-match-p piem-patch-subject-re
- (message-field-value "subject"))
+ (and (string-match-p
+ piem-patch-subject-re
+ (rfc2047-decode-string
+ (message-field-value "subject")))
(buffer-substring-no-properties
(point-min) (point-max)))))))
(cons (lambda () (insert patch))