[Webkit-unassigned] [Bug 17381] New: [CURL] Regression: data URL parsing broken after DeprecatedString removal (Acid2)

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Feb 15 16:45:33 PST 2008


http://bugs.webkit.org/show_bug.cgi?id=17381

           Summary: [CURL] Regression: data URL parsing broken after
                    DeprecatedString removal (Acid2)
           Product: WebKit
           Version: 525+ (Nightly build)
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: Gtk, Curl
          Severity: Normal
          Priority: P2
         Component: New Bugs
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: alp at atoker.com


WebCore/platform/network/curl/ResourceHandleManager.cpp uses String to carry
binary data, which doesn't work properly.

The fix will be something along the lines of:

    char* ret = 0;
+    size_t retLen = 0;
+
     if (base64 && !data.isEmpty()) {
         // Use the GLib Base64 if available, since WebCore's decoder isn't
         // general-purpose and fails on Acid3 test 97 (whitespace).
 #ifdef USE_GLIB_BASE64
         gsize outLength;
         guchar* out = g_base64_decode(data.latin1().data(), &outLength);
-        data = String(reinterpret_cast<char*>(out), outLength);
-        g_free(out);
+        //g_free(out);
+        ret = (char*)out;
+        retLen = outLength;
 #else





+    if (retLen)
+        client->didReceiveData(handle, ret, retLen, 0);


-- 
Configure bugmail: http://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list