[PATCH] Fix for bug 70753: charset not detected when more than one "charset" in Content-Type

Thiago Macieira thiago.macieira at kdemail.net
Thu Dec 18 17:59:28 GMT 2003


Hello,

I the attached patch fixes bug #70753. When receiving a header like:
Content-Type: text/html; charset=ISO-8859-4; charset=ISO-8859-4 

kio_http sets the "charset" metadata to:
"iso-8859-4; charset=iso-8859-4"

That is, it ignores the second ; and treats the rest of the line after the = 
as one single parameter.

The attached patch solves that by making it treat each parameter 
independently, separated by ;

Is it ok to commit?
-- 
  Thiago Macieira  -  Registered Linux user #65028
   thiagom (AT) mail (dot) com
    ICQ UIN: 1967141   PGP/GPG: 0x6EF45358; fingerprint:
    E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kio_http-doublecharset.patch
Type: text/x-diff
Size: 1672 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20031218/b4941384/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: signature
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20031218/b4941384/attachment.sig>


More information about the kde-core-devel mailing list