Title: [164789] releases/WebKitGTK/webkit-2.4/Source/WebKit2
Revision
164789
Author
carlo...@webkit.org
Date
2014-02-27 03:34:58 -0800 (Thu, 27 Feb 2014)

Log Message

Merge r164787 - [GTK] Web Inspector doesn't work with network process enabled
https://bugs.webkit.org/show_bug.cgi?id=127651

Reviewed by Sergio Villar Senin.

The problem is that the web inspector loads so many resources,
that when using the network process, a lot of IPC traffic is
generated causing the send buffer of the socket to be full. When
that happens sendmsg() fails with EAGAIN, because we are using non
blocking sockets, and we are not handling neither EAGAIN nor
EWOULDBLOCK errors (we do when reading from the socket, though).

* Platform/IPC/unix/ConnectionUnix.cpp:
(IPC::Connection::readyReadHandler): Add a log message to know
when reading from the socket fails for any unhandled error.
(IPC::Connection::sendOutgoingMessage): Handle EAGAIN and
EWOULDBLOCK errors to try again in those cases. Also add a log
message for unhandled errors.

Modified Paths

Diff

Modified: releases/WebKitGTK/webkit-2.4/Source/WebKit2/ChangeLog (164788 => 164789)


--- releases/WebKitGTK/webkit-2.4/Source/WebKit2/ChangeLog	2014-02-27 11:34:42 UTC (rev 164788)
+++ releases/WebKitGTK/webkit-2.4/Source/WebKit2/ChangeLog	2014-02-27 11:34:58 UTC (rev 164789)
@@ -1,3 +1,24 @@
+2014-02-27  Carlos Garcia Campos  <cgar...@igalia.com>
+
+        [GTK] Web Inspector doesn't work with network process enabled
+        https://bugs.webkit.org/show_bug.cgi?id=127651
+
+        Reviewed by Sergio Villar Senin.
+
+        The problem is that the web inspector loads so many resources,
+        that when using the network process, a lot of IPC traffic is
+        generated causing the send buffer of the socket to be full. When
+        that happens sendmsg() fails with EAGAIN, because we are using non
+        blocking sockets, and we are not handling neither EAGAIN nor
+        EWOULDBLOCK errors (we do when reading from the socket, though).
+
+        * Platform/IPC/unix/ConnectionUnix.cpp:
+        (IPC::Connection::readyReadHandler): Add a log message to know
+        when reading from the socket fails for any unhandled error.
+        (IPC::Connection::sendOutgoingMessage): Handle EAGAIN and
+        EWOULDBLOCK errors to try again in those cases. Also add a log
+        message for unhandled errors.
+
 2014-02-24  Carlos Garcia Campos  <cgar...@igalia.com>
 
         [GTK] Remove unneeded method webkitWebViewBaseRequestExitFullScreen

Modified: releases/WebKitGTK/webkit-2.4/Source/WebKit2/Platform/IPC/unix/ConnectionUnix.cpp (164788 => 164789)


--- releases/WebKitGTK/webkit-2.4/Source/WebKit2/Platform/IPC/unix/ConnectionUnix.cpp	2014-02-27 11:34:42 UTC (rev 164788)
+++ releases/WebKitGTK/webkit-2.4/Source/WebKit2/Platform/IPC/unix/ConnectionUnix.cpp	2014-02-27 11:34:58 UTC (rev 164789)
@@ -357,6 +357,7 @@
                 return;
 
             // FIXME: Handle other errors here?
+            WTFLogAlways("Error receiving IPC message: %s", strerror(errno));
             return;
         }
 
@@ -521,8 +522,11 @@
 
     int bytesSent = 0;
     while ((bytesSent = sendmsg(m_socketDescriptor, &message, 0)) == -1) {
-        if (errno != EINTR)
-            return false;
+        if (errno == EINTR || errno == EAGAIN || errno == EWOULDBLOCK)
+            continue;
+
+        WTFLogAlways("Error sending IPC message: %s", strerror(errno));
+        return false;
     }
     return true;
 }
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to