Closed chris-martin closed 1 year ago
I'm sorry but I don't understand this proposal a bit. Where can I find NullSocketAddress
?
I apologize, I forgot the words aren't completely spelled. I was attempting to refer to NullSockAddr.
OK. I understand.
Which do you prefer:
NullSockAddr
onlysendWithFds
with NullSockAddr
hiddenIf I could only choose one, I'd prefer the second.
OK. Would you make a PR including the followings?
sendWithFds
NullSockAddr
from Internal
Sounds good, will do when I find some time.
@chris-martin Gentle ping.
From my brief experimentation with Wayland, it has seemed like the Wayland server expects that when you send a message with a file descriptor parameter, it expects the message and the fd to be sent together in a single
sendmsg
call. Thenetwork
library presently does not have any explicit support for doing this.Currently, in my own code I have a copy of
NullSocketAddress
, which is internally defined in the network package but not exported.So then I can use
sendBufMsg
the way the network package does internally...... where
datas
contains the wayland message andcontrols
contains the file descriptor.Proposal one (nearly no effort): It would be nice if the network library simply exported the
NullSocketAddress
type so that I could use it instead of duplicating it.Proposal two (slightly more work): Some explicit support for sending data and file descriptors in a single call?