[SOUP] Provide logging for SocketStreamHandleSoup
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 25 Oct 2012 00:49:44 +0000 (00:49 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 25 Oct 2012 00:49:44 +0000 (00:49 +0000)
https://bugs.webkit.org/show_bug.cgi?id=100215

Patch by Seokju Kwon <seokju.kwon@samsung.com> on 2012-10-24
Reviewed by Alexey Proskuryakov.

Add logging to SocketStreamHandleSoup to facilitate debugging.

* platform/network/soup/SocketStreamHandleSoup.cpp:
(WebCore::SocketStreamHandle::SocketStreamHandle):
(WebCore::SocketStreamHandle::~SocketStreamHandle):
(WebCore::SocketStreamHandle::platformSend):
(WebCore::SocketStreamHandle::platformClose):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@132435 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/platform/network/soup/SocketStreamHandleSoup.cpp

index 883a2b7a25e4c4fb9495f11e4f5e0d73b15a621f..78e0d9448b21676448e83270077e81c665e45873 100644 (file)
@@ -1,3 +1,18 @@
+2012-10-24  Seokju Kwon  <seokju.kwon@samsung.com>
+
+        [SOUP] Provide logging for SocketStreamHandleSoup
+        https://bugs.webkit.org/show_bug.cgi?id=100215
+
+        Reviewed by Alexey Proskuryakov.
+
+        Add logging to SocketStreamHandleSoup to facilitate debugging.
+
+        * platform/network/soup/SocketStreamHandleSoup.cpp:
+        (WebCore::SocketStreamHandle::SocketStreamHandle):
+        (WebCore::SocketStreamHandle::~SocketStreamHandle):
+        (WebCore::SocketStreamHandle::platformSend):
+        (WebCore::SocketStreamHandle::platformClose):
+
 2012-10-24  Nico Weber  <thakis@chromium.org>
 
         Pass on exif orientation from ImageSource when using the open-source image decoders
index 7aa6cccb8ffe481c27561fa0a5e9ecddb31c7523..c536583134c0a4f4da9e72b796fbd010ce9ef542 100644 (file)
@@ -84,6 +84,7 @@ SocketStreamHandle::SocketStreamHandle(const KURL& url, SocketStreamHandleClient
     : SocketStreamHandleBase(url, client)
     , m_readBuffer(0)
 {
+    LOG(Network, "SocketStreamHandle %p new client %p", this, m_client);
     unsigned int port = url.hasPort() ? url.port() : (url.protocolIs("wss") ? 443 : 80);
 
     m_id = activateHandle(this);
@@ -96,6 +97,7 @@ SocketStreamHandle::SocketStreamHandle(const KURL& url, SocketStreamHandleClient
 
 SocketStreamHandle::~SocketStreamHandle()
 {
+    LOG(Network, "SocketStreamHandle %p delete", this);
     // If for some reason we were destroyed without closing, ensure that we are deactivated.
     deactivateHandle(this);
     setClient(0);
@@ -153,6 +155,7 @@ void SocketStreamHandle::writeReady()
 
 int SocketStreamHandle::platformSend(const char* data, int length)
 {
+    LOG(Network, "SocketStreamHandle %p platformSend", this);
     GOwnPtr<GError> error;
     gssize written = g_pollable_output_stream_write_nonblocking(m_outputStream.get(), data, length, 0, &error.outPtr());
     if (error) {
@@ -173,6 +176,7 @@ int SocketStreamHandle::platformSend(const char* data, int length)
 
 void SocketStreamHandle::platformClose()
 {
+    LOG(Network, "SocketStreamHandle %p platformClose", this);
     // We remove this handle from the active handles list first, to disable all callbacks.
     deactivateHandle(this);
     stopWaitingForSocketWritability();