Last modified: 2014-09-23 23:16:21 UTC
Created attachment 8624 [details] Patch for UserMailer Some broken mailers (f**king M$ Exchange) corrupt quoted-printable headers that are longer than 255 characters. We solved it simply by changing Quoted-Printable encoding to MIME-Base64 (patch is attached, just for notice). Or are there also problems with Base64? Why do you use Quoted-Printable?
The patch doesn't follow our coding guidelines
Well, base64 is obviously a lot less legible for the case of latin text. :) Quoted-printable is also easier to debug even for non-Latin text as the individual bytes can be seen, whereas base64 squishes a bitstream together. I have no idea whether base64 is actually more compatible or not than quoted-printable. This patch also adds two code paths and output formats: one path taken when iconv_mime_encode() is available -- where long output will be split over lines -- and one when it's not, where long output is not split. Are there any compatibility issues with long unwrapped lines of base64 stuff? Any differences in behavior to be expected between the two?
:) agreed :) (In reply to comment #1) > The patch doesn't follow our coding guidelines Surely yes ( for example it's hard to add ( spaces after braces ) everywhere when everything other that you work on does not have them ), but it's attached just for information. :) > This patch also adds two code paths and output formats Agree, it's not good. I can't tell about the difference by now, need to check.
Btw, is there some automatic tool to check your code formatting style?
(In reply to comment #4) > Btw, is there some automatic tool to check your code formatting style? http://svn.wikimedia.org/svnroot/mediawiki/trunk/tools/code-utils/stylize.php
It looks like this patch has received some review, so I am adding the "reviewed" keyword. Vitaliy, do you have time to update it, and interest in doing so? Thanks. https://www.mediawiki.org/wiki/Coding_conventions has had some updates since June, so linking for reference.