[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
darin
darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 08:37:11 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit e074d0bb2bba152d0e8e938080596406e003513e
Author: darin <darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Mon Apr 26 22:01:49 2004 +0000
- fixed <rdar://problem/3634145>: "REGRESSION: nil-deref in QTextCodec::toUnicode every time loading page at wiki.wordpress.org"
* kwq/KWQKURL.mm:
(KURL::KURL): Simplify check for nil that defaults to UTF-8.
(KURL::decode_string): Add a similar test here.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@6488 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 8b4a850..1971081 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,11 @@
+2004-04-26 Darin Adler <darin at apple.com>
+
+ - fixed <rdar://problem/3634145>: "REGRESSION: nil-deref in QTextCodec::toUnicode every time loading page at wiki.wordpress.org"
+
+ * kwq/KWQKURL.mm:
+ (KURL::KURL): Simplify check for nil that defaults to UTF-8.
+ (KURL::decode_string): Add a similar test here.
+
2004-04-26 David Hyatt <hyatt at apple.com>
Implement the quirk that makes the <body> and <html> size to fill the viewport in quirks mode. This
diff --git a/WebCore/kwq/KWQKURL.mm b/WebCore/kwq/KWQKURL.mm
index 4172248..1c5ddf2 100644
--- a/WebCore/kwq/KWQKURL.mm
+++ b/WebCore/kwq/KWQKURL.mm
@@ -363,9 +363,9 @@ KURL::KURL(const KURL &base, const QString &relative, const QTextCodec *codec)
}
}
- QCString decoded = codec
- ? codec->fromUnicode(s)
- : QTextCodec(kCFStringEncodingUTF8).fromUnicode(s);
+ static QTextCodec UTF8Codec(kCFStringEncodingUTF8);
+
+ QCString decoded = (codec ? codec : &UTF8Codec)->fromUnicode(s)
strBuffer = strdup(decoded);
str = strBuffer;
}
@@ -893,6 +893,8 @@ QString KURL::prettyURL() const
QString KURL::decode_string(const QString &urlString, const QTextCodec *codec)
{
+ static QTextCodec UTF8Codec(kCFStringEncodingUTF8);
+
QString result("");
char staticBuffer[2048];
@@ -936,7 +938,7 @@ QString KURL::decode_string(const QString &urlString, const QTextCodec *codec)
}
// Decode the bytes into Unicode characters.
- QString decoded = codec->toUnicode(buffer, p - buffer);
+ QString decoded = (codec ? codec : &UTF8Codec)->toUnicode(buffer, p - buffer);
if (decoded.isEmpty()) {
continue;
}
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list