[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: Re: branches/kdepim/enterprise/kdepim/kmail
From: Andreas Hartmetz <ahartmetz () gmail ! com>
Date: 2008-03-07 11:13:40
Message-ID: 200803071213.41014.ahartmetz () gmail ! com
[Download RAW message or body]
Am Donnerstag 06 März 2008 18:32:00 schrieb Volker Krause:
> SVN commit 782964 by vkrause:
>
> Fix corruption of binary attachments introduced in revision 771698.
>
> The actual problem here is that EncodingDetector::decode(_const_ QByteArray
> &data) replaces all 0x00 bytes in data with 0x20 although being const.
>
Crazy, just crazy. Thanks for fixing it.
> CCMAIL: ahartmetz@gmail.com
>
>
> M +4 -1 kmcomposewin.cpp
>
>
> --- branches/kdepim/enterprise/kdepim/kmail/kmcomposewin.cpp #782963:782964
> @@ -2758,7 +2758,10 @@
> EncodingDetector ed;
> KLocale *loc = KGlobal::locale();
> ed.setAutoDetectLanguage( EncodingDetector::scriptForLanguageCode (
> loc->language() ) ); - ed.decode( ( *it ).data );
> + // ### FIXME decode(_const_ QByteArray &) replaces 0x00 bytes by 0x20
> in the parameter + // despite being const, which obviously breaks binary
> attachments. + QByteArray copy = (*it).data.copy();
> + ed.decode( copy );
> partCharset = ed.encoding();
> if (partCharset.isEmpty()) //shouldn't happen
> partCharset = mCharset;
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic