Does FreeBSD have sendmmsg or recvmmsg system calls?
Mark Delany
c2h at romeo.emu.st
Mon Jan 4 10:17:55 UTC 2016
> Why is a signal lost in the scenario you described ?
Because the return can only indicate a signal/error *or* a batch of
messages but not both and the semantics of recvmsg() means that both
could occur.
Don't just consider signals, consider any -1/errno return from
recvmsg() such as -1/EAGAIN or -1/ENOBUFS or -1/EFAULT.
If one emulates recvmmsg() via multiple calls to recvmsg() and the
emulation receives 'n' messages via recvmsg() then gets a -1/EFAULT
return on message 'n'+1 then what does it return to the caller?
If it returns 'n' messages then the EFAULT is lost.
If it returns -1/EFAULT then the 'n' messages are lost.
Mark.
More information about the freebsd-net
mailing list