Commit graph

5 commits

Author SHA1 Message Date
David van Moolenbroek 9e3e032c26 UDS: sendmsg/recvmsg fixes
- sendmsg: the accumulation of multiple in-flight file descriptors was
  already described in the comments; now the code actually does what
  the comments say :) -- also, added robustness in case of a failure;
- recvmsg: only create a socket rights message if there are file
  descriptors pending at all;
- recvmsg: copy back the control message length;
- recvmsg: use CMSG_SPACE instead of CMSG_LEN to compute sizes.

Not sure if all of this is now working according to specification,
but at least tmux seems to be happy with it.

Change-Id: I8d076c14c3ff3220b7fea730e0f08f4b4254ede5
2014-03-01 09:04:58 +01:00
David van Moolenbroek f3d8aa65ac UDS: add support for FIONREAD
Change-Id: I50030012b408242a86f8c55017429acdadff49d1
2014-03-01 09:04:58 +01:00
David van Moolenbroek 3e8346a8e8 UDS: support for nonblocking sockets
This patch includes several other fixes, which are now tested in the
test56 test set.

Change-Id: I9535d5a6c072abf966252838522c5f65b353c6c2
2014-03-01 09:04:57 +01:00
David van Moolenbroek 1e07186caf UDS: clean up source code
- move VFS calls to a separate source file;
- solve a few subtle bugs, mostly in error handling;
- simplify debug reporting code;
- make a few definitions more independent;
- restyle to something closer to KNF.

Change-Id: I7b0537adfccac8b92b5cc3e78dac9f5ce3c79f03
2014-03-01 09:04:57 +01:00
David van Moolenbroek b003ed0929 UDS: split off from PFS
Change-Id: I769cbd64aa6e5e85a797caf0f8bbb4c20e145263
2014-03-01 09:04:57 +01:00