From f3f3fc5267e297d4375ac20a3aa59181320a460d Mon Sep 17 00:00:00 2001 From: ShengHuo ZHU Date: Wed, 7 May 2003 23:24:08 +0000 Subject: [PATCH] (message-forward-subject-name-subject): Fix the case when the field "from" doesn't exist. --- lisp/ChangeLog | 3 +++ lisp/message.el | 10 ++++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 66506a22f..ba9a9eac6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -2,6 +2,9 @@ * message.el (message-setup-1): Setup alternative email before generate-headers. + + (message-forward-subject-name-subject): Fix the case when the + field "from" doesn't exist. 2003-05-07 Dave Love diff --git a/lisp/message.el b/lisp/message.el index b03b8abdb..c7764e9dc 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -5851,10 +5851,12 @@ news, Source is the list of newsgroups is was posted to." (concat "[" (let ((prefix (or (message-fetch-field "newsgroups") - (cdr - (mail-header-parse-address - (mail-decode-encoded-word-string - (message-fetch-field "from")))) + (let ((from (message-fetch-field "from"))) + (and from + (cdr + (mail-header-parse-address + (mail-decode-encoded-word-string + from))))) "(nowhere)"))) (if message-forward-decoded-p prefix -- 2.34.1