[PATCH] Add a MIME-Version header to e-mails
- From
Karl Hasselström <kha@treskal.com>
- Date
- Nov 6, 2006, 07:45 UTC
- Message-ID
- <20061106074532.10376.60478.stgit@localhost>
- In-Reply-To
- <eile19$p7r$1@sea.gmane.org>
From: Karl Hasselström <kha@treskal.com>
This is required by some mail servers that want to change the transfer encoding of the mail.
Signed-off-by: Karl Hasselström <kha@treskal.com> ---
OK, this is a test to see if adding MIME-Version makes the problem go away. I don't have any other way to test this than sending a patch to the list. :-)
stgit/commands/mail.py | 12 +++++------- 1 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/stgit/commands/mail.py b/stgit/commands/mail.py index 45f7438..c428d67 100644 --- a/stgit/commands/mail.py +++ b/stgit/commands/mail.py @@ -271,13 +271,11 @@ def __get_signers_list(msg): return addr_list def __build_extra_headers(): - """Build extra headers like content-type etc. - """ - headers = 'Content-Type: text/plain; charset=utf-8; format=fixed\n' - headers += 'Content-Transfer-Encoding: 8bit\n' - headers += 'User-Agent: StGIT/%s\n' % version.version - - return headers + """Build extra headers like content-type etc.""" + return ('MIME-Version: 1.0\n' + 'Content-Type: text/plain; charset=utf-8; format=fixed\n' + 'Content-Transfer-Encoding: 8bit\n' + 'User-Agent: StGIT/%s\n' % version.version) def edit_message(msg):