aboutsummaryrefslogtreecommitdiff
path: root/src/libutil/file-descriptor.hh
AgeCommit message (Collapse)Author
2024-08-09libutil: rename and optimize closeMostFDseldritch horrors
this is only used to close non-stdio files in derivation sandboxes. we may as well encode that in its name, drop the unnecessary integer set, and use close_range to deal with the actual closing of files. not only is this clearer, it also makes sandbox setup on linux fast by 1ms each Change-Id: Id90e259a49c7bc896189e76bfbbf6ef2c0bcd3b2
2024-07-03libutil: convert drainFD to a Bytes generatoreldritch horrors
the `*Source` name is a slight misnomer since we do also have a Source type, but we can probably live with this for time being. Change-Id: I54eb2e59a4009014e324797f16b80b962759c7d3
2024-05-29util.{hh,cc}: Split out unix-domain-socket.{hh,cc}Tom Hubrecht
Change-Id: I3f9a628e0f8998b6146f5caa8ae9842361a66b8b
2024-05-29util.{hh,cc}: Split out file-descriptor.{hh,cc}Tom Hubrecht
Change-Id: I0dd0f9a9c2003fb887e076127e7f825fd3289c76