Gnus development mailing list
 help / color / mirror / Atom feed
* Workaround for quoted printable encoding of attachments
@ 1999-09-11 12:41 Rene H. Larsen
  1999-09-12  0:55 ` Shenghuo ZHU
  0 siblings, 1 reply; 4+ messages in thread
From: Rene H. Larsen @ 1999-09-11 12:41 UTC (permalink / raw)


If you, like me, have problems with binary attachments in pGnus being
encoded as quoted printable instead of in base64, this may help you.

Just insert this into your .gnus:

(defun mm-qp-or-base64 () 'base64)

This will effectively disable pGnus' (apparently broken) heuristics to
determine whether a file is binary, and always choose base64
encoding. Unfortunately, "text/*" attachments will then also be base64
encoded. On the other hand, "message/rfc822" attachments are
unaffected.

This does not fix the underlying problem, but should merely be
regarded as a workaround.

HTH.
-- 
#!/usr/bin/perl -w
for(0..12){$b[$_]="|".($_==6?"-":" ")x78}for(0..78){substr($b[-
(sin($_*3.1415/22)-1)*6.499],$_,1)="*"}print join "\n",@b,"";


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Workaround for quoted printable encoding of attachments
  1999-09-11 12:41 Workaround for quoted printable encoding of attachments Rene H. Larsen
@ 1999-09-12  0:55 ` Shenghuo ZHU
  1999-09-12  3:14   ` Rene H. Larsen
  0 siblings, 1 reply; 4+ messages in thread
From: Shenghuo ZHU @ 1999-09-12  0:55 UTC (permalink / raw)


>>>>> "R" == Rene H Larsen <renehl@post1.tele.dk> writes:

R> If you, like me, have problems with binary attachments in pGnus being
R> encoded as quoted printable instead of in base64, this may help you.

R> Just insert this into your .gnus:

R> (defun mm-qp-or-base64 () 'base64)

R> This will effectively disable pGnus' (apparently broken) heuristics to
R> determine whether a file is binary, and always choose base64
R> encoding. Unfortunately, "text/*" attachments will then also be base64
R> encoded. On the other hand, "message/rfc822" attachments are
R> unaffected.

R> This does not fix the underlying problem, but should merely be
R> regarded as a workaround.

I guess your solution is not appropriate. Why not try the following
code in your .gnus?

(setq mm-content-transfer-encoding-defaults
  '(("text/x-patch" 8bit)
    ("text/.*" qp-or-base64)
    ("message/rfc822" 8bit)
    ("application/emacs-lisp" 8bit)
    ("application/x-patch" 8bit)
    (".*" base64)))

-- 
Shenghuo ZHU


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Workaround for quoted printable encoding of attachments
  1999-09-12  0:55 ` Shenghuo ZHU
@ 1999-09-12  3:14   ` Rene H. Larsen
  1999-09-12 14:54     ` Shenghuo ZHU
  0 siblings, 1 reply; 4+ messages in thread
From: Rene H. Larsen @ 1999-09-12  3:14 UTC (permalink / raw)


Shenghuo ZHU <zsh@cs.rochester.edu> writes:

> >>>>> "R" == Rene H Larsen <renehl@post1.tele.dk> writes:
> 
> R> If you, like me, have problems with binary attachments in pGnus being
> R> encoded as quoted printable instead of in base64, this may help you.
> [...]
> R> This does not fix the underlying problem, but should merely be
> R> regarded as a workaround.
> 
> I guess your solution is not appropriate. Why not try the following
> code in your .gnus?
> 
> (setq mm-content-transfer-encoding-defaults
>   '(("text/x-patch" 8bit)
>     ("text/.*" qp-or-base64)
>     ("message/rfc822" 8bit)
>     ("application/emacs-lisp" 8bit)
>     ("application/x-patch" 8bit)
>     (".*" base64)))

This is much nicer, thanks.  My workaround was just a desperate try at 
solving an immediate problem.

Why is something like this not the default, by the way?  It doesn't
make sense to QP encode most binary formats since newlines might be
screwed up at the receiving end.
-- 
#!/usr/bin/perl -w
for(0..12){$b[$_]="|".($_==6?"-":" ")x78}for(0..78){substr($b[-
(sin($_*3.1415/22)-1)*6.499],$_,1)="*"}print join "\n",@b,"";


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Workaround for quoted printable encoding of attachments
  1999-09-12  3:14   ` Rene H. Larsen
@ 1999-09-12 14:54     ` Shenghuo ZHU
  0 siblings, 0 replies; 4+ messages in thread
From: Shenghuo ZHU @ 1999-09-12 14:54 UTC (permalink / raw)


>>>>> "R" == Rene H Larsen <renehl@post1.tele.dk> writes:

R> Why is something like this not the default, by the way?  It doesn't
R> make sense to QP encode most binary formats since newlines might be
R> screwed up at the receiving end.

I guess it is for shorter encoded message.

Have you tried one of my patches sent a few days ago? That will fix
bug of broken QP encoded message by folding long lines. I am not sure
whether you got the same bug.

-- 
Shenghuo ZHU


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~1999-09-12 14:54 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-09-11 12:41 Workaround for quoted printable encoding of attachments Rene H. Larsen
1999-09-12  0:55 ` Shenghuo ZHU
1999-09-12  3:14   ` Rene H. Larsen
1999-09-12 14:54     ` Shenghuo ZHU

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).