[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677

mjs mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 08:09:43 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit f7e95cb636acbb9b2d87ea19c02c1698e795945e
Author: mjs <mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Nov 6 17:06:00 2003 +0000

            Reviewed by Darin.
    
    	- fixed 3475397 - REGRESSION: relative URLs on page load test sometimes contain garbage, leading to missing images
    
            * kwq/KWQKURL.mm:
            (KURL::KURL): When constructing from NSURL, null-terminate the raw
    	bytes since KURL::parse expects a null-terminated C string. It
    	might be even better to pass a length to parse, but this fix is
    	simple and does the job.
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@5403 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 08041b0..17234f5 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,15 @@
+2003-11-06  Maciej Stachowiak  <mjs at apple.com>
+
+        Reviewed by Darin.
+
+	- fixed 3475397 - REGRESSION: relative URLs on page load test sometimes contain garbage, leading to missing images
+	
+        * kwq/KWQKURL.mm:
+        (KURL::KURL): When constructing from NSURL, null-terminate the raw
+	bytes since KURL::parse expects a null-terminated C string. It
+	might be even better to pass a length to parse, but this fix is
+	simple and does the job.
+
 2003-11-05  Darin Adler  <darin at apple.com>
 
         Reviewed by Maciej.
diff --git a/WebCore/kwq/KWQKURL.mm b/WebCore/kwq/KWQKURL.mm
index e975f86..26fbc50 100644
--- a/WebCore/kwq/KWQKURL.mm
+++ b/WebCore/kwq/KWQKURL.mm
@@ -241,8 +241,9 @@ KURL::KURL(NSURL *url)
 {
     if (url) {
         CFIndex bufferLength = CFURLGetBytes((CFURLRef)url, NULL, 0);
-        char *bytes = new char [bufferLength];
+        char *bytes = new char [bufferLength + 1];
         CFURLGetBytes((CFURLRef)url, (UInt8 *)bytes, bufferLength);
+	bytes[bufferLength] = '\0';
         if (bytes[0] == '/') {
             QString fileUrl = QString("file:") + bytes;
             parse(fileUrl.ascii(), &fileUrl);

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list