[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

tony at chromium.org tony at chromium.org
Wed Dec 22 13:15:36 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit b9b143f9b8a7c9ff7a16d5a8af534ad21cfbab02
Author: tony at chromium.org <tony at chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Fri Sep 10 00:41:35 2010 +0000

    2010-09-09  Sheriff Bot  <webkit.review.bot at gmail.com>
    
            Unreviewed, rolling out r67119.
            http://trac.webkit.org/changeset/67119
            https://bugs.webkit.org/show_bug.cgi?id=45505
    
            Extra newlines in results (Requested by tony^work on #webkit).
    
            * platform/chromium-linux/fast/dom/HTMLLinkElement/prefetch-expected.txt: Added.
            * platform/chromium-mac/fast/dom/HTMLLinkElement/prefetch-expected.txt: Added.
            * platform/chromium/test_expectations.txt:
    2010-09-09  Sheriff Bot  <webkit.review.bot at gmail.com>
    
            Unreviewed, rolling out r67119.
            http://trac.webkit.org/changeset/67119
            https://bugs.webkit.org/show_bug.cgi?id=45505
    
            Extra newlines in results (Requested by tony^work on #webkit).
    
            * DumpRenderTree/chromium/LayoutTestController.cpp:
            (LayoutTestController::LayoutTestController):
            (LayoutTestController::reset):
            * DumpRenderTree/chromium/LayoutTestController.h:
            * DumpRenderTree/chromium/TestShell.h:
            * DumpRenderTree/chromium/WebViewHost.cpp:
            (printResponseDescription):
            (printNodeDescription):
            (printRangeDescription):
            (WebViewHost::shouldBeginEditing):
            (WebViewHost::shouldEndEditing):
            (WebViewHost::shouldInsertNode):
            (WebViewHost::shouldChangeSelectedRange):
            (WebViewHost::shouldDeleteRange):
            (WebViewHost::shouldApplyStyle):
            (WebViewHost::didBeginEditing):
            (WebViewHost::didChangeSelection):
            (WebViewHost::didChangeContents):
            (WebViewHost::didEndEditing):
            (WebViewHost::decidePolicyForNavigation):
            (WebViewHost::didCancelClientRedirect):
            (WebViewHost::didStartProvisionalLoad):
            (WebViewHost::didReceiveServerRedirectForProvisionalLoad):
            (WebViewHost::didFailProvisionalLoad):
            (WebViewHost::didCommitProvisionalLoad):
            (WebViewHost::didFinishDocumentLoad):
            (WebViewHost::didHandleOnloadEvents):
            (WebViewHost::didFailLoad):
            (WebViewHost::didFinishLoad):
            (WebViewHost::didChangeLocationWithinPage):
            (WebViewHost::willSendRequest):
            (WebViewHost::didReceiveResponse):
            (WebViewHost::didFinishResourceLoad):
            (WebViewHost::didFailResourceLoad):
            (WebViewHost::didDisplayInsecureContent):
            (WebViewHost::didRunInsecureContent):
            (WebViewHost::printFrameDescription):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@67133 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 14b087e..3e7c938 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,15 @@
+2010-09-09  Sheriff Bot  <webkit.review.bot at gmail.com>
+
+        Unreviewed, rolling out r67119.
+        http://trac.webkit.org/changeset/67119
+        https://bugs.webkit.org/show_bug.cgi?id=45505
+
+        Extra newlines in results (Requested by tony^work on #webkit).
+
+        * platform/chromium-linux/fast/dom/HTMLLinkElement/prefetch-expected.txt: Added.
+        * platform/chromium-mac/fast/dom/HTMLLinkElement/prefetch-expected.txt: Added.
+        * platform/chromium/test_expectations.txt:
+
 2010-09-09  Mihai Parparita  <mihaip at chromium.org>
 
         Reviewed by Tony Chang.
diff --git a/LayoutTests/platform/chromium-linux/fast/dom/HTMLLinkElement/prefetch-expected.txt b/LayoutTests/platform/chromium-linux/fast/dom/HTMLLinkElement/prefetch-expected.txt
new file mode 100644
index 0000000..a3468f1
--- /dev/null
+++ b/LayoutTests/platform/chromium-linux/fast/dom/HTMLLinkElement/prefetch-expected.txt
@@ -0,0 +1,3 @@
+CONSOLE MESSAGE: line 6: Uncaught TypeError: Object [object Object] has no method 'dumpResourceResponseMIMETypes'
+
+This test requires DumpRenderTree to see the log of what resources are loaded.
diff --git a/LayoutTests/platform/chromium-mac/fast/dom/HTMLLinkElement/prefetch-expected.txt b/LayoutTests/platform/chromium-mac/fast/dom/HTMLLinkElement/prefetch-expected.txt
new file mode 100644
index 0000000..a3468f1
--- /dev/null
+++ b/LayoutTests/platform/chromium-mac/fast/dom/HTMLLinkElement/prefetch-expected.txt
@@ -0,0 +1,3 @@
+CONSOLE MESSAGE: line 6: Uncaught TypeError: Object [object Object] has no method 'dumpResourceResponseMIMETypes'
+
+This test requires DumpRenderTree to see the log of what resources are loaded.
diff --git a/LayoutTests/platform/chromium/test_expectations.txt b/LayoutTests/platform/chromium/test_expectations.txt
index 8cc4e09..bd8c086 100644
--- a/LayoutTests/platform/chromium/test_expectations.txt
+++ b/LayoutTests/platform/chromium/test_expectations.txt
@@ -2673,6 +2673,11 @@ BUG46603 : fast/frames/lots-of-objects.html = PASS TIMEOUT
 // LayoutTestController::pageProperty is not implemented for Chromium yet.
 BUGWK35961 : printing/page-rule-selection.html = TEXT
 
+// Needs to implement layoutTestController.dumpResourceResponseMIMETypes()
+BUG46872 : fast/preloader = TEXT
+BUG46872 : fast/dom/HTMLLinkElement/prefetch.html = TIMEOUT
+BUG46872 : http/tests/loading/preload-slow-loading.php = TEXT
+
 BUG47035 WIN DEBUG : fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html = PASS TEXT
 
 // CSS3 Hyphenation landed in http://trac.webkit.org/changeset/61548
@@ -2794,6 +2799,8 @@ BUG48859 WIN : fast/inline/continuation-outlines-with-layers-2.html = IMAGE+TEXT
 // Need investigation.
 BUGWK38016 WIN : svg/custom/foreign-object-skew.svg = FAIL
 
+BUG49031 WIN LINUX MAC : http/tests/mime/uppercase-mime-type.html = MISSING
+
 BUG49021 : userscripts/mixed-case-stylesheet.html = TEXT
 BUG49021 : userscripts/simple-stylesheet.html = TEXT
 BUG49021 : userscripts/user-style-all-frames.html = TEXT
diff --git a/WebKitTools/ChangeLog b/WebKitTools/ChangeLog
index 69c0cf4..e4fe819 100644
--- a/WebKitTools/ChangeLog
+++ b/WebKitTools/ChangeLog
@@ -1,3 +1,49 @@
+2010-09-09  Sheriff Bot  <webkit.review.bot at gmail.com>
+
+        Unreviewed, rolling out r67119.
+        http://trac.webkit.org/changeset/67119
+        https://bugs.webkit.org/show_bug.cgi?id=45505
+
+        Extra newlines in results (Requested by tony^work on #webkit).
+
+        * DumpRenderTree/chromium/LayoutTestController.cpp:
+        (LayoutTestController::LayoutTestController):
+        (LayoutTestController::reset):
+        * DumpRenderTree/chromium/LayoutTestController.h:
+        * DumpRenderTree/chromium/TestShell.h:
+        * DumpRenderTree/chromium/WebViewHost.cpp:
+        (printResponseDescription):
+        (printNodeDescription):
+        (printRangeDescription):
+        (WebViewHost::shouldBeginEditing):
+        (WebViewHost::shouldEndEditing):
+        (WebViewHost::shouldInsertNode):
+        (WebViewHost::shouldChangeSelectedRange):
+        (WebViewHost::shouldDeleteRange):
+        (WebViewHost::shouldApplyStyle):
+        (WebViewHost::didBeginEditing):
+        (WebViewHost::didChangeSelection):
+        (WebViewHost::didChangeContents):
+        (WebViewHost::didEndEditing):
+        (WebViewHost::decidePolicyForNavigation):
+        (WebViewHost::didCancelClientRedirect):
+        (WebViewHost::didStartProvisionalLoad):
+        (WebViewHost::didReceiveServerRedirectForProvisionalLoad):
+        (WebViewHost::didFailProvisionalLoad):
+        (WebViewHost::didCommitProvisionalLoad):
+        (WebViewHost::didFinishDocumentLoad):
+        (WebViewHost::didHandleOnloadEvents):
+        (WebViewHost::didFailLoad):
+        (WebViewHost::didFinishLoad):
+        (WebViewHost::didChangeLocationWithinPage):
+        (WebViewHost::willSendRequest):
+        (WebViewHost::didReceiveResponse):
+        (WebViewHost::didFinishResourceLoad):
+        (WebViewHost::didFailResourceLoad):
+        (WebViewHost::didDisplayInsecureContent):
+        (WebViewHost::didRunInsecureContent):
+        (WebViewHost::printFrameDescription):
+
 2010-09-09  Michael Saboff  <msaboff at apple.com>
 
         Unreviewed, adding myself to committers list.
diff --git a/WebKitTools/DumpRenderTree/chromium/LayoutTestController.cpp b/WebKitTools/DumpRenderTree/chromium/LayoutTestController.cpp
index f896241..8e08c4c 100644
--- a/WebKitTools/DumpRenderTree/chromium/LayoutTestController.cpp
+++ b/WebKitTools/DumpRenderTree/chromium/LayoutTestController.cpp
@@ -83,7 +83,6 @@ LayoutTestController::LayoutTestController(TestShell* shell)
     bindMethod("dumpBackForwardList", &LayoutTestController::dumpBackForwardList);
     bindMethod("dumpFrameLoadCallbacks", &LayoutTestController::dumpFrameLoadCallbacks);
     bindMethod("dumpResourceLoadCallbacks", &LayoutTestController::dumpResourceLoadCallbacks);
-    bindMethod("dumpResourceResponseMIMETypes", &LayoutTestController::dumpResourceResponseMIMETypes);
     bindMethod("dumpStatusCallbacks", &LayoutTestController::dumpWindowStatusChanges);
     bindMethod("dumpTitleChanges", &LayoutTestController::dumpTitleChanges);
     bindMethod("setAcceptsEditing", &LayoutTestController::setAcceptsEditing);
@@ -286,12 +285,6 @@ void LayoutTestController::dumpResourceLoadCallbacks(const CppArgumentList&, Cpp
     result->setNull();
 }
 
-void LayoutTestController::dumpResourceResponseMIMETypes(const CppArgumentList&, CppVariant* result)
-{
-    m_dumpResourceResponseMIMETypes = true;
-    result->setNull();
-}
-
 void LayoutTestController::dumpChildFrameScrollPositions(const CppArgumentList&, CppVariant* result)
 {
     m_dumpChildFrameScrollPositions = true;
@@ -487,7 +480,6 @@ void LayoutTestController::reset()
     m_dumpEditingCallbacks = false;
     m_dumpFrameLoadCallbacks = false;
     m_dumpResourceLoadCallbacks = false;
-    m_dumpResourceResponseMIMETypes = false;
     m_dumpBackForwardList = false;
     m_dumpChildFrameScrollPositions = false;
     m_dumpChildFramesAsText = false;
diff --git a/WebKitTools/DumpRenderTree/chromium/LayoutTestController.h b/WebKitTools/DumpRenderTree/chromium/LayoutTestController.h
index 268bed5..55c8c8b 100644
--- a/WebKitTools/DumpRenderTree/chromium/LayoutTestController.h
+++ b/WebKitTools/DumpRenderTree/chromium/LayoutTestController.h
@@ -96,16 +96,6 @@ public:
     // dump all frames as plain text if the dumpAsText flag is set.
     // It takes no arguments, and ignores any that may be present.
     void dumpChildFramesAsText(const CppArgumentList&, CppVariant*);
-    
-    // This function sets a flag that tells the test_shell to dump a descriptive
-    // line for each resource load callback. It takes no arguments, and ignores
-    // any that may be present.
-    void dumpResourceLoadCallbacks(const CppArgumentList&, CppVariant*);    
-    
-    // This function sets a flag that tells the test_shell to dump the MIME type
-    // for each resource that was loaded. It takes no arguments, and ignores any
-    // that may be present.
-    void dumpResourceResponseMIMETypes(const CppArgumentList&, CppVariant*);
 
     // This function sets a flag that tells the test_shell to dump all calls
     // to window.status().
@@ -236,6 +226,7 @@ public:
     // are needed to pass the layout tests.
     void dumpAsWebArchive(const CppArgumentList&, CppVariant*);
     void dumpTitleChanges(const CppArgumentList&, CppVariant*);
+    void dumpResourceLoadCallbacks(const CppArgumentList&, CppVariant*);
     void setMainFrameIsFirstResponder(const CppArgumentList&, CppVariant*);
     void display(const CppArgumentList&, CppVariant*);
     void testRepaint(const CppArgumentList&, CppVariant*);
@@ -332,8 +323,6 @@ public:
     bool shouldDumpFrameLoadCallbacks() { return m_dumpFrameLoadCallbacks; }
     void setShouldDumpFrameLoadCallbacks(bool value) { m_dumpFrameLoadCallbacks = value; }
     bool shouldDumpResourceLoadCallbacks() {return m_dumpResourceLoadCallbacks; }
-    void setShouldDumpResourceResponseMIMETypes(bool value) { m_dumpResourceResponseMIMETypes = value; }
-    bool shouldDumpResourceResponseMIMETypes() {return m_dumpResourceResponseMIMETypes; }
     bool shouldDumpStatusCallbacks() { return m_dumpWindowStatusChanges; }
     bool shouldDumpSelectionRect() { return m_dumpSelectionRect; }
     bool shouldDumpBackForwardList() { return m_dumpBackForwardList; }
@@ -453,10 +442,6 @@ private:
     // If true, the test_shell will output a descriptive line for each resource
     // load callback.
     bool m_dumpResourceLoadCallbacks;
-    
-    // If true, the test_shell will output the MIME type for each resource that 
-    // was loaded.
-    bool m_dumpResourceResponseMIMETypes;
 
     // If true, the test_shell will produce a dump of the back forward list as
     // well.
diff --git a/WebKitTools/DumpRenderTree/chromium/TestShell.h b/WebKitTools/DumpRenderTree/chromium/TestShell.h
index d3ed5fa..cb5f862 100644
--- a/WebKitTools/DumpRenderTree/chromium/TestShell.h
+++ b/WebKitTools/DumpRenderTree/chromium/TestShell.h
@@ -107,7 +107,6 @@ public:
     void setFocus(WebKit::WebWidget*, bool enable);
     bool shouldDumpFrameLoadCallbacks() const { return (m_testIsPreparing || m_testIsPending) && layoutTestController()->shouldDumpFrameLoadCallbacks(); }
     bool shouldDumpResourceLoadCallbacks() const  { return (m_testIsPreparing || m_testIsPending) && layoutTestController()->shouldDumpResourceLoadCallbacks(); }
-    bool shouldDumpResourceResponseMIMETypes() const  { return (m_testIsPreparing || m_testIsPending) && layoutTestController()->shouldDumpResourceResponseMIMETypes(); }
     void setIsLoading(bool flag) { m_isLoading = flag; }
 
     // Called by the LayoutTestController to signal test completion.
diff --git a/WebKitTools/DumpRenderTree/chromium/WebViewHost.cpp b/WebKitTools/DumpRenderTree/chromium/WebViewHost.cpp
index c994b8d..fae3f56 100644
--- a/WebKitTools/DumpRenderTree/chromium/WebViewHost.cpp
+++ b/WebKitTools/DumpRenderTree/chromium/WebViewHost.cpp
@@ -156,7 +156,7 @@ static string URLDescription(const GURL& url)
 static void printResponseDescription(const WebURLResponse& response)
 {
     if (response.isNull()) {
-        puts("(null)");
+        fputs("(null)", stdout);
         return;
     }
     string url = response.url().spec();
@@ -168,17 +168,17 @@ static void printResponseDescription(const WebURLResponse& response)
 static void printNodeDescription(const WebNode& node, int exception)
 {
     if (exception) {
-        puts("ERROR");
+        fputs("ERROR", stdout);
         return;
     }
     if (node.isNull()) {
-        puts("(null)");
+        fputs("(null)", stdout);
         return;
     }
-    puts(node.nodeName().utf8().data());
+    fputs(node.nodeName().utf8().data(), stdout);
     const WebNode& parent = node.parentNode();
     if (!parent.isNull()) {
-        puts(" > ");
+        fputs(" > ", stdout);
         printNodeDescription(parent, 0);
     }
 }
@@ -186,7 +186,7 @@ static void printNodeDescription(const WebNode& node, int exception)
 static void printRangeDescription(const WebRange& range)
 {
     if (range.isNull()) {
-        puts("(null)");
+        fputs("(null)", stdout);
         return;
     }
     printf("range from %d of ", range.startOffset());
@@ -277,9 +277,9 @@ void WebViewHost::didStopLoading()
 bool WebViewHost::shouldBeginEditing(const WebRange& range)
 {
     if (layoutTestController()->shouldDumpEditingCallbacks()) {
-        puts("EDITING DELEGATE: shouldBeginEditingInDOMRange:");
+        fputs("EDITING DELEGATE: shouldBeginEditingInDOMRange:", stdout);
         printRangeDescription(range);
-        puts("\n");
+        fputs("\n", stdout);
     }
     return layoutTestController()->acceptsEditing();
 }
@@ -287,9 +287,9 @@ bool WebViewHost::shouldBeginEditing(const WebRange& range)
 bool WebViewHost::shouldEndEditing(const WebRange& range)
 {
     if (layoutTestController()->shouldDumpEditingCallbacks()) {
-        puts("EDITING DELEGATE: shouldEndEditingInDOMRange:");
+        fputs("EDITING DELEGATE: shouldEndEditingInDOMRange:", stdout);
         printRangeDescription(range);
-        puts("\n");
+        fputs("\n", stdout);
     }
     return layoutTestController()->acceptsEditing();
 }
@@ -297,9 +297,9 @@ bool WebViewHost::shouldEndEditing(const WebRange& range)
 bool WebViewHost::shouldInsertNode(const WebNode& node, const WebRange& range, WebEditingAction action)
 {
     if (layoutTestController()->shouldDumpEditingCallbacks()) {
-        ("EDITING DELEGATE: shouldInsertNode:");
+        fputs("EDITING DELEGATE: shouldInsertNode:", stdout);
         printNodeDescription(node, 0);
-        puts(" replacingDOMRange:");
+        fputs(" replacingDOMRange:", stdout);
         printRangeDescription(range);
         printf(" givenAction:%s\n", editingActionDescription(action).c_str());
     }
@@ -320,9 +320,9 @@ bool WebViewHost::shouldChangeSelectedRange(
     const WebRange& fromRange, const WebRange& toRange, WebTextAffinity affinity, bool stillSelecting)
 {
     if (layoutTestController()->shouldDumpEditingCallbacks()) {
-        puts("EDITING DELEGATE: shouldChangeSelectedDOMRange:");
+        fputs("EDITING DELEGATE: shouldChangeSelectedDOMRange:", stdout);
         printRangeDescription(fromRange);
-        puts(" toDOMRange:");
+        fputs(" toDOMRange:", stdout);
         printRangeDescription(toRange);
         printf(" affinity:%s stillSelecting:%s\n",
                textAffinityDescription(affinity).c_str(),
@@ -334,9 +334,9 @@ bool WebViewHost::shouldChangeSelectedRange(
 bool WebViewHost::shouldDeleteRange(const WebRange& range)
 {
     if (layoutTestController()->shouldDumpEditingCallbacks()) {
-        puts("EDITING DELEGATE: shouldDeleteDOMRange:");
+        fputs("EDITING DELEGATE: shouldDeleteDOMRange:", stdout);
         printRangeDescription(range);
-        puts("\n");
+        fputs("\n", stdout);
     }
     return layoutTestController()->acceptsEditing();
 }
@@ -346,7 +346,7 @@ bool WebViewHost::shouldApplyStyle(const WebString& style, const WebRange& range
     if (layoutTestController()->shouldDumpEditingCallbacks()) {
         printf("EDITING DELEGATE: shouldApplyStyle:%s toElementsInDOMRange:", style.utf8().data());
         printRangeDescription(range);
-        puts("\n");
+        fputs("\n", stdout);
     }
     return layoutTestController()->acceptsEditing();
 }
@@ -365,13 +365,13 @@ void WebViewHost::didBeginEditing()
 {
     if (!layoutTestController()->shouldDumpEditingCallbacks())
         return;
-    puts("EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification\n");
+    fputs("EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification\n", stdout);
 }
 
 void WebViewHost::didChangeSelection(bool isEmptySelection)
 {
     if (layoutTestController()->shouldDumpEditingCallbacks())
-        puts("EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification\n");
+        fputs("EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification\n", stdout);
     // No need to update clipboard with the selected text in DRT.
 }
 
@@ -379,14 +379,14 @@ void WebViewHost::didChangeContents()
 {
     if (!layoutTestController()->shouldDumpEditingCallbacks())
         return;
-    puts("EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification\n");
+    fputs("EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification\n", stdout);
 }
 
 void WebViewHost::didEndEditing()
 {
     if (!layoutTestController()->shouldDumpEditingCallbacks())
         return;
-    puts("EDITING DELEGATE: webViewDidEndEditing:WebViewDidEndEditingNotification\n");
+    fputs("EDITING DELEGATE: webViewDidEndEditing:WebViewDidEndEditingNotification\n", stdout);
 }
 
 bool WebViewHost::handleCurrentKeyboardEvent()
@@ -661,10 +661,10 @@ WebNavigationPolicy WebViewHost::decidePolicyForNavigation(
     printf("Policy delegate: attempt to load %s with navigation type '%s'",
            URLDescription(request.url()).c_str(), webNavigationTypeToString(type));
     if (!originatingNode.isNull()) {
-        puts(" originating from ");
+        fputs(" originating from ", stdout);
         printNodeDescription(originatingNode, 0);
     }
-    puts("\n");
+    fputs("\n", stdout);
     if (m_policyDelegateIsPermissive)
         result = WebKit::WebNavigationPolicyCurrentTab;
     else
@@ -720,7 +720,7 @@ void WebViewHost::didCancelClientRedirect(WebFrame* frame)
     if (!m_shell->shouldDumpFrameLoadCallbacks())
         return;
     printFrameDescription(frame);
-    puts(" - didCancelClientRedirectForFrame\n");
+    fputs(" - didCancelClientRedirectForFrame\n", stdout);
 }
 
 void WebViewHost::didCreateDataSource(WebFrame*, WebDataSource* ds)
@@ -732,7 +732,7 @@ void WebViewHost::didStartProvisionalLoad(WebFrame* frame)
 {
     if (m_shell->shouldDumpFrameLoadCallbacks()) {
         printFrameDescription(frame);
-        puts(" - didStartProvisionalLoadForFrame\n");
+        fputs(" - didStartProvisionalLoadForFrame\n", stdout);
     }
 
     if (!m_topLoadingFrame)
@@ -740,7 +740,7 @@ void WebViewHost::didStartProvisionalLoad(WebFrame* frame)
 
     if (layoutTestController()->stopProvisionalFrameLoads()) {
         printFrameDescription(frame);
-        puts(" - stopping load in didStartProvisionalLoadForFrame callback\n");
+        fputs(" - stopping load in didStartProvisionalLoadForFrame callback\n", stdout);
         frame->stopLoading();
     }
     updateAddressBar(frame->view());
@@ -750,7 +750,7 @@ void WebViewHost::didReceiveServerRedirectForProvisionalLoad(WebFrame* frame)
 {
     if (m_shell->shouldDumpFrameLoadCallbacks()) {
         printFrameDescription(frame);
-        puts(" - didReceiveServerRedirectForProvisionalLoadForFrame\n");
+        fputs(" - didReceiveServerRedirectForProvisionalLoadForFrame\n", stdout);
     }
     updateAddressBar(frame->view());
 }
@@ -759,7 +759,7 @@ void WebViewHost::didFailProvisionalLoad(WebFrame* frame, const WebURLError& err
 {
     if (m_shell->shouldDumpFrameLoadCallbacks()) {
         printFrameDescription(frame);
-        puts(" - didFailProvisionalLoadWithError\n");
+        fputs(" - didFailProvisionalLoadWithError\n", stdout);
     }
 
     locationChangeDone(frame);
@@ -772,7 +772,7 @@ void WebViewHost::didCommitProvisionalLoad(WebFrame* frame, bool isNewNavigation
 {
     if (m_shell->shouldDumpFrameLoadCallbacks()) {
         printFrameDescription(frame);
-        puts(" - didCommitLoadForFrame\n");
+        fputs(" - didCommitLoadForFrame\n", stdout);
     }
     updateForCommittedLoad(frame, isNewNavigation);
 }
@@ -801,7 +801,7 @@ void WebViewHost::didFinishDocumentLoad(WebFrame* frame)
 {
     if (m_shell->shouldDumpFrameLoadCallbacks()) {
         printFrameDescription(frame);
-        puts(" - didFinishDocumentLoadForFrame\n");
+        fputs(" - didFinishDocumentLoadForFrame\n", stdout);
     } else {
         unsigned pendingUnloadEvents = frame->unloadListenerCount();
         if (pendingUnloadEvents) {
@@ -815,7 +815,7 @@ void WebViewHost::didHandleOnloadEvents(WebFrame* frame)
 {
     if (m_shell->shouldDumpFrameLoadCallbacks()) {
         printFrameDescription(frame);
-        puts(" - didHandleOnloadEventsForFrame\n");
+        fputs(" - didHandleOnloadEventsForFrame\n", stdout);
     }
 }
 
@@ -823,7 +823,7 @@ void WebViewHost::didFailLoad(WebFrame* frame, const WebURLError& error)
 {
     if (m_shell->shouldDumpFrameLoadCallbacks()) {
         printFrameDescription(frame);
-        puts(" - didFailLoadWithError\n");
+        fputs(" - didFailLoadWithError\n", stdout);
     }
     locationChangeDone(frame);
 }
@@ -832,7 +832,7 @@ void WebViewHost::didFinishLoad(WebFrame* frame)
 {
     if (m_shell->shouldDumpFrameLoadCallbacks()) {
         printFrameDescription(frame);
-        puts(" - didFinishLoadForFrame\n");
+        fputs(" - didFinishLoadForFrame\n", stdout);
     }
     updateAddressBar(frame->view());
     locationChangeDone(frame);
@@ -849,7 +849,7 @@ void WebViewHost::didChangeLocationWithinPage(WebFrame* frame)
 {
     if (m_shell->shouldDumpFrameLoadCallbacks()) {
         printFrameDescription(frame);
-        puts(" - didChangeLocationWithinPageForFrame\n");
+        fputs(" - didChangeLocationWithinPageForFrame\n", stdout);
     }
 }
 
@@ -875,11 +875,11 @@ void WebViewHost::willSendRequest(WebFrame*, unsigned identifier, WebURLRequest&
                URLDescription(mainDocumentURL).c_str(),
                request.httpMethod().utf8().data());
         printResponseDescription(redirectResponse);
-        puts("\n");
+        fputs("\n", stdout);
     }
 
     if (!redirectResponse.isNull() && m_blocksRedirects) {
-        puts("Returning null for this redirect\n");
+        fputs("Returning null for this redirect\n", stdout);
         // To block the request, we set its URL to an empty one.
         request.setURL(WebURL());
         return;
@@ -915,27 +915,19 @@ void WebViewHost::willSendRequest(WebFrame*, unsigned identifier, WebURLRequest&
 
 void WebViewHost::didReceiveResponse(WebFrame*, unsigned identifier, const WebURLResponse& response)
 {
-    if (m_shell->shouldDumpResourceLoadCallbacks()) {
-        printResourceDescription(identifier);
-        puts(" - didReceiveResponse ");
-        printResponseDescription(response);
-        puts("\n");
-    }
-    if (m_shell->shouldDumpResourceResponseMIMETypes()) {
-        GURL url = response.url();
-        WebString mimeType = response.mimeType();
-        printf("%s has MIME type %s\n",
-            url.ExtractFileName().c_str(),
-            // Simulate NSURLResponse's mapping of empty/unknown MIME types to application/octet-stream
-            mimeType.isEmpty() ? "application/octet-stream" : mimeType.utf8().data());
-    }
+    if (!m_shell->shouldDumpResourceLoadCallbacks())
+        return;
+    printResourceDescription(identifier);
+    fputs(" - didReceiveResponse ", stdout);
+    printResponseDescription(response);
+    fputs("\n", stdout);
 }
 
 void WebViewHost::didFinishResourceLoad(WebFrame*, unsigned identifier)
 {
     if (m_shell->shouldDumpResourceLoadCallbacks()) {
         printResourceDescription(identifier);
-        puts(" - didFinishLoading\n");
+        fputs(" - didFinishLoading\n", stdout);
     }
     m_resourceIdentifierMap.remove(identifier);
 }
@@ -944,9 +936,9 @@ void WebViewHost::didFailResourceLoad(WebFrame*, unsigned identifier, const WebU
 {
     if (m_shell->shouldDumpResourceLoadCallbacks()) {
         printResourceDescription(identifier);
-        puts(" - didFailLoadingWithError: ");
-        puts(webkit_support::MakeURLErrorDescription(error).c_str());
-        puts("\n");
+        fputs(" - didFailLoadingWithError: ", stdout);
+        fputs(webkit_support::MakeURLErrorDescription(error).c_str(), stdout);
+        fputs("\n", stdout);
     }
     m_resourceIdentifierMap.remove(identifier);
 }
@@ -954,13 +946,13 @@ void WebViewHost::didFailResourceLoad(WebFrame*, unsigned identifier, const WebU
 void WebViewHost::didDisplayInsecureContent(WebFrame*)
 {
     if (m_shell->shouldDumpFrameLoadCallbacks())
-        puts("didDisplayInsecureContent\n");
+        fputs("didDisplayInsecureContent\n", stdout);
 }
 
 void WebViewHost::didRunInsecureContent(WebFrame*, const WebSecurityOrigin& origin)
 {
     if (m_shell->shouldDumpFrameLoadCallbacks())
-        puts("didRunInsecureContent\n");
+        fputs("didRunInsecureContent\n", stdout);
 }
 
 bool WebViewHost::allowScript(WebFrame*, bool enabledPerSettings)
@@ -1208,14 +1200,14 @@ void WebViewHost::printFrameDescription(WebFrame* webframe)
     string name8 = webframe->name().utf8();
     if (webframe == webView()->mainFrame()) {
         if (!name8.length()) {
-            puts("main frame");
+            fputs("main frame", stdout);
             return;
         }
         printf("main frame \"%s\"", name8.c_str());
         return;
     }
     if (!name8.length()) {
-        puts("frame (anonymous)");
+        fputs("frame (anonymous)", stdout);
         return;
     }
     printf("frame \"%s\"", name8.c_str());

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list