End of Life Ruby 3.0 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →
instance method
BasicSocket#recvmsg_nonblock
basicsocket.recvmsg_nonblock(maxdatalen=nil, flags=0, maxcontrollen=nil, opts={}) => [data, sender_addrinfo, rflags, *controls]
ext/socket/lib/socket.rb
View on GitHub ↗
# File tmp/rubies/ruby-3.0.5/ext/socket/lib/socket.rb, line 442
def recvmsg_nonblock(dlen = nil, flags = 0, clen = nil,
scm_rights: false, exception: true)
__recvmsg_nonblock(dlen, flags, clen, scm_rights, exception)
end
recvmsg receives a message using recvmsg(2) system call in non-blocking manner.
It is similar to BasicSocket#recvmsg but non-blocking flag is set before the system call and it doesn’t retry the system call.
By specifying a keyword argument exception to false, you can indicate that recvmsg_nonblock should not raise an IO::WaitReadable exception, but return the symbol :wait_readable instead.