From e6b8dfdc30be6bf9e84ad09119bac684d750a4a3 Mon Sep 17 00:00:00 2001 From: yamaoka Date: Sat, 3 Oct 1998 03:55:31 +0000 Subject: [PATCH] * lisp/message.el (message-make-user-agent): Replace with the new code again. It is based on MORIOKA-san's code. --- lisp/message.el | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/lisp/message.el b/lisp/message.el index 2b4121c..22f767a 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -3149,9 +3149,9 @@ give as trustworthy answer as possible." (defvar gnus-inviolable-extended-version) (defun message-make-user-agent () - "Return user-agent info if the value `message-user-agent' is non-nil and the -\"User-Agent\" field which includes the same value of `message-user-agent' does -not exist in the narrowed header." + "Return user-agent info if the value `message-user-agent' is non-nil. If the +\"User-Agent\" field has already exist, it's value will be added in the return +string." (when message-user-agent (save-excursion (goto-char (point-min)) @@ -3163,10 +3163,8 @@ not exist in the narrowed header." p (match-end 0) end (std11-field-end) user-agent (buffer-substring-no-properties p end)) - (unless (string-match (regexp-quote message-user-agent) - user-agent) - (delete-region start (1+ end)) - (concat message-user-agent " " user-agent))) + (delete-region start (1+ end)) + (concat message-user-agent " " user-agent)) message-user-agent))))) (defun message-generate-headers (headers) -- 1.7.10.4