Issue #13362 has been updated by akr (Akira Tanaka).


I think we can try it to see the incompatibility is really minor or not.
So, it should be described in NEWS.

----------------------------------------
Feature #13362: [PATCH] socket: avoid fcntl for read/write_nonblock on Linux
https://bugs.ruby-lang.org/issues/13362#change-64371

* Author: normalperson (Eric Wong)
* Status: Feedback
* Priority: Normal
* Assignee: 
* Target version: 
----------------------------------------
On platforms where MSG_DONTWAIT works reliably on all sockets
(so far, I know of Linux), we can avoid fcntl syscalls and
implement IO#write_nonblock and IO#read_nonblock in terms of the
socket-specific send and recv family of syscalls.

This avoids side effects on the socket, and also encourages
generic code to be written in cases where IO wrappers like
OpenSSL::SSL::SSLSocket are used.


I could've sworn I sent something like this years ago, but
maybe I'm confusing it with kgio or socket_dontwait.


---Files--------------------------------
0001-socket-avoid-fcntl-for-read-write_nonblock-on-Linux.patch (3.1 KB)


-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:ruby-core-request / ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>