No deltas via email anymore?

Stephen McKay smckay at internode.on.net
Thu Jan 21 00:07:37 UTC 2010


On Wednesday, 20th January 2010, "Julian H. Stacey" wrote:

>75 seems low, considering MS addicts write extremely long
>lines at times (I suppose that's why - sigh).
>
>	uuencode 	61
>	fmt		65
>	MIME base64	72
>	punch cards	72
>	MSexchange	75
>	ctm_rmail	76
>
>I guess there would be no objection if you wrote patches for:
>	- ctm_rmail to also support receipt of smaller lines.
>	- ctm_smail to optionally generate shorter lines.

It would be trivial to change ctm_smail to send lines of 72 characters.
It would reduce the encoding efficiency slightly, but not enough to
worry about.  It is not worth making it optional.  I'll probably do
this when I get a moment.

Changing ctm_rmail to attempt to repair various mangling of the input
is more difficult and unlikely to be worth the trouble.  If ctm_smail
is changed, only new shorter lines will show up in future messages and
no mangling should occur then anyway.

>> From:		Andre Albsmeier <Andre.Albsmeier at siemens.com> 
>> Now the deltas arrive like this:
>> 
>> CTM_MAIL BEGIN src-7.0895.gz 1 1
>> H4sIAGI5VksCA8VZ+28bNxL+2foreG5R2HnIfD8ctEASO70AqVs0PlyvdweBT3sRaVe3u0riHvq
>> /
>> 35ArPyT5IbcBzoZJaUkOZz4OZ75Zvz79YfLq+Pu3J4iOMepa/1whbQSimGBMiKFUGC5/RePR69M
>> f
>> 3rxHY9/PJl1v+0WHYAYfGsk50h4bE3RyRmEeXJSBGSqtY1GHEKlCSQdtVBJEU8yoEEQIzw1LQhj
>> L

Amusingly, this uncovered a 15 year old bug in ctm_rmail.  Sorry about
that. :-)  The decode_line() routine has no way of reporting successful
decoding with a 0 length output.  The "illegal character" error is spurious.

    ctm_rmail: line 3: illegal character: '/'
    ctm_rmail: src-7.0895.gz 1/1 discarded

The true error report should have been a checksum failure after the
whole file had been read.  However, since this is only a cosmetic error
on corrupt input with no security implications (no array bounds exceeded,
for example), we can leave this one.

Alternatively, if people feel the need for more checking, I could add
code to reject line lengths that are not a multiple of 4, and perhaps
to skip blank lines.  Yes?

Stephen.  (No, not the other Stephen!)


More information about the ctm-users mailing list