Last modified: 2014-09-23 23:32:12 UTC
Created attachment 3817 [details]
patch to fix mime.info parsing regular expression
A regular expression that's slightly off in MimeMagic's constructor causes it to keep whitespace between the last mime-type and the [MEDIATYPE] when parsing each line of the mime.info file. Each line is later explode()d on whitespace, causing MimeInfo to think each line contains at least two mime-types, which signifies an alias should be written from mime type 2+, usually the empty string, to the first mime type in that line.
This turns out not to hurt anything functionally, but does waste some cycles needlessly overpopulating the $mMimeTypeAliases array.
A patch consisting of a fixed regular expression is attached.
*Bulk BZ Change: +Patch to open bugs with patches attached that are missing the keyword*
Mike, thanks for your patch, and my apologies that it's taken so very long to get back to you. Your patch still applies cleanly to trunk, hurray! :-) I'm adding the "need-review" keyword to ask for code review, and other keywords/components as I infer is appropriate. Thanks again.
Mike, thanks again for the patch and my apologies that it's taken so long for us to respond. Are you interested in using developer access to directly suggest it into our Git source control system, which would get it reviewed and possibly incorporated faster?