Gnus development mailing list
 help / color / mirror / Atom feed
From: Vladimir Volovich <vvv@vvv.vsu.ru>
Subject: Re: treating "broken" base64 parts
Date: 11 Jan 2000 23:56:49 +0300	[thread overview]
Message-ID: <m3so04gwdq.fsf@vvv.vsu.ru> (raw)
In-Reply-To: Vladimir Volovich's message of "10 Jan 2000 14:00:46 +0300"

[-- Attachment #1: Type: text/plain, Size: 1038 bytes --]

"VV" == Vladimir Volovich writes:

 VV> i often receive messages from mailing lists which have the
 VV> following form:
[...]
 VV> From: someone Subject: test To: someone Content-Type: text/plain;
 VV> charset=koi8-r Content-Transfer-Encoding: base64 OtherHeaders:
 VV> ...

 VV> 5MzRINrB1NLB18vJINDSxcTMwcfBwCDPwtPVxMnU2CDgzsnLz8QgySDFx88gy8nSyczMyd7F
 VV> 08vVwCDewdPU2CDOwSDQ0sXEzcXUDQrQ0snHz8TOz9PUySDLIM7B28XN1SDExczVLiDuwSDN
 VV> ...
 VV> yc/OLCDF08zJIM7FIMnNxcXUxQ0K1MHLz9fPx88uDQpodHRwOi8vY2hzbGF2Lmh5cGVybWFy
 VV> dC5uZXQNCg0K4czFy9PFyg0KDQoNCg==

 VV> -------------------------------------------------------------------------------
 VV> -=COOL-LIST=- Project // Mail Lists service on something.com

 VV> I.e., the text is a 1-part messages with CTE=base64, but mailing
 VV> list software adds a trailer lines. Gnus does not display these
 VV> messages correctly, i.e. what i see is the undecoded base64
 VV> text. I wonder, could gnus automagically treat such messages?

well, here is a patch which solves this problem for me:


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: mm-bodies.el.diff --]
[-- Type: text/x-patch, Size: 602 bytes --]

--- mm-bodies.el.orig	Tue Jan 11 23:51:31 2000
+++ mm-bodies.el	Tue Jan 11 23:52:28 2000
@@ -154,8 +154,12 @@
 				  ;; Some mailers insert whitespace
 				  ;; junk at the end which
 				  ;; base64-decode-region dislikes.
+				  ;; Also remove possible junk which could
+				  ;; have been added by mailing list software.
 				  (save-excursion
-				    (goto-char (point-max))
+				    (goto-char (point-min))
+				    (re-search-forward "^[\t ]*$")
+				    (delete-region (point) (point-max))
 				    (skip-chars-backward "\n\t ")
 				    (delete-region (point) (point-max))
 				    (point))))

[-- Attachment #3: Type: text/plain, Size: 320 bytes --]


could someone with CVS rw access apply this if you find it correct?

BTW, i just noticed that the Lines: header generated by gnus is
incorrect. So the old bug with Lines: header is still there. :-(
Could someone please fix it? (calculate Lines: NOT for MML message,
but for a MIME message)

	Best regards, -- Vladimir.

      reply	other threads:[~2000-01-11 20:56 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-01-10 11:00 Vladimir Volovich
2000-01-11 20:56 ` Vladimir Volovich [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m3so04gwdq.fsf@vvv.vsu.ru \
    --to=vvv@vvv.vsu.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).