Title: [267538] trunk/Source/_javascript_Core
Revision
267538
Author
[email protected]
Date
2020-09-24 11:23:57 -0700 (Thu, 24 Sep 2020)

Log Message

[PlayStation] Stop raising SIGPIPE when client side of RemoteInspector dies
https://bugs.webkit.org/show_bug.cgi?id=216805

Reviewed by Don Olmstead.

When communication is stopped caused by peer crash or non-polite close, SIGPIPE will be
raised on BSD (and maybe on Linux). We prefer to handle those events by returning error.

On Windows, there's no such fancy feature from the beginning.

* inspector/remote/socket/posix/RemoteInspectorSocketPOSIX.cpp:
(Inspector::Socket::read):
(Inspector::Socket::write):

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (267537 => 267538)


--- trunk/Source/_javascript_Core/ChangeLog	2020-09-24 17:47:53 UTC (rev 267537)
+++ trunk/Source/_javascript_Core/ChangeLog	2020-09-24 18:23:57 UTC (rev 267538)
@@ -1,3 +1,19 @@
+2020-09-24  Basuke Suzuki  <[email protected]>
+
+        [PlayStation] Stop raising SIGPIPE when client side of RemoteInspector dies
+        https://bugs.webkit.org/show_bug.cgi?id=216805
+
+        Reviewed by Don Olmstead.
+
+        When communication is stopped caused by peer crash or non-polite close, SIGPIPE will be
+        raised on BSD (and maybe on Linux). We prefer to handle those events by returning error.
+
+        On Windows, there's no such fancy feature from the beginning.
+
+        * inspector/remote/socket/posix/RemoteInspectorSocketPOSIX.cpp:
+        (Inspector::Socket::read):
+        (Inspector::Socket::write):
+
 2020-09-24  Angelos Oikonomopoulos  <[email protected]>
 
         [MIPS] Broken build after r267371

Modified: trunk/Source/_javascript_Core/inspector/remote/socket/posix/RemoteInspectorSocketPOSIX.cpp (267537 => 267538)


--- trunk/Source/_javascript_Core/inspector/remote/socket/posix/RemoteInspectorSocketPOSIX.cpp	2020-09-24 17:47:53 UTC (rev 267537)
+++ trunk/Source/_javascript_Core/inspector/remote/socket/posix/RemoteInspectorSocketPOSIX.cpp	2020-09-24 18:23:57 UTC (rev 267538)
@@ -206,7 +206,7 @@
 {
     ASSERT(isValid(socket));
 
-    ssize_t readSize = ::read(socket, buffer, bufferSize);
+    ssize_t readSize = ::recv(socket, buffer, bufferSize, MSG_NOSIGNAL);
     if (readSize >= 0)
         return static_cast<size_t>(readSize);
 
@@ -218,7 +218,7 @@
 {
     ASSERT(isValid(socket));
 
-    ssize_t writeSize = ::write(socket, data, size);
+    ssize_t writeSize = ::send(socket, data, size, MSG_NOSIGNAL);
     if (writeSize >= 0)
         return static_cast<size_t>(writeSize);
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to