Gnus development mailing list
 help / color / mirror / Atom feed
* word-encoder creates short lines; possible bug in encoder
@ 2000-06-01  9:54 Vladimir Volovich
  2000-06-01 14:33 ` Shenghuo ZHU
  0 siblings, 1 reply; 2+ messages in thread
From: Vladimir Volovich @ 2000-06-01  9:54 UTC (permalink / raw)


Hi!

1. when gnus uses encoded-word encoding (of type B or Q) in headers,
it tends to create more short lines than necessary. Say, i received a
message with subject:

Subject: =?koi8-r?B?Iu7P18HRINDB0sHEycfNwSDEzNEg09TB0s/KINTFz9LJySI=?=

when replying to this message, gnus created a subject like:

Subject: Re: "=?koi8-r?b?7s/XwdEg0MHSwcTJx83B?=
 =?koi8-r?b?IMTM0SDT1MHSz8og1MXP?=
 =?koi8-r?b?0snJ?="

it seems that gnus used AT LEAST one extra line, creating short lines
in headers. Is it possible to change the function which encodes
headers to use optimal line number (i.e. try to use the smallest
possible number of lines, breaking only really wide lines)?

2. AFAIR, RFC says that encoded-word should not appear inside quotes.
is the above header (created by gnus) correct in this respect?
i mean "=?koi8-r?b? .... ?="
should the quotes be "hidden" inside encoded-word?

3. maybe, gnus should switch to SEMI library (SEMI is Emacs MIME
   Interfaces) which provides basic fubctions e.b. for word-encoding,
   etc.  Because AFAIK SEMI is very strict WRT RFC-compliance.

Best,
v.




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

* Re: word-encoder creates short lines; possible bug in encoder
  2000-06-01  9:54 word-encoder creates short lines; possible bug in encoder Vladimir Volovich
@ 2000-06-01 14:33 ` Shenghuo ZHU
  0 siblings, 0 replies; 2+ messages in thread
From: Shenghuo ZHU @ 2000-06-01 14:33 UTC (permalink / raw)


>>>>> "VV" == Vladimir Volovich <vvv@vvv.vsu.ru> writes:

VV> Hi!
VV> 1. when gnus uses encoded-word encoding (of type B or Q) in headers,
VV> it tends to create more short lines than necessary. Say, i received a
VV> message with subject:

VV> Subject: =?koi8-r?B?Iu7P18HRINDB0sHEycfNwSDEzNEg09TB0s/KINTFz9LJySI=?=

VV> when replying to this message, gnus created a subject like:

VV> Subject: Re: "=?koi8-r?b?7s/XwdEg0MHSwcTJx83B?=
VV>  =?koi8-r?b?IMTM0SDT1MHSz8og1MXP?=
VV>  =?koi8-r?b?0snJ?="

VV> it seems that gnus used AT LEAST one extra line, creating short lines
VV> in headers. Is it possible to change the function which encodes
VV> headers to use optimal line number (i.e. try to use the smallest
VV> possible number of lines, breaking only really wide lines)?

According to RFC2047, 

   Each 'encoded-word' MUST represent an integral number of
   characters.  A multi-octet character may not be split across
   adjacent 'encoded-word's.

It is difficult to decide where to break the line.  For the safety
reason, the subject is broken into several lines.  If you can figure
out the optimal algorithm to break wide lines, that's great.

VV> 2. AFAIR, RFC says that encoded-word should not appear inside
VV> quotes.  is the above header (created by gnus) correct in this
VV> respect?  i mean "=?koi8-r?b? .... ?=" should the quotes be
VV> "hidden" inside encoded-word?

It is a bug. 

Shenghuo



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

end of thread, other threads:[~2000-06-01 14:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-06-01  9:54 word-encoder creates short lines; possible bug in encoder Vladimir Volovich
2000-06-01 14:33 ` 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).