| Commit message (Collapse) | Author | Age | Files | Lines | |
|---|---|---|---|---|---|
| * | ExecFork: Simplify closing and make it safe | Julian Andres Klode | 2025-10-20 | 1 | -32/+0 |
| | | | | | | | | | | Implement a wrapper around FD_CLOEXEC and use it in place of the raw fcntl(). This wrapper _Exit()s the child if the operation failed. Restructure the close_range() handling to simply mark all fds for closing first and then "reopen" the ones we should keep. | ||||
| * | Add some comments and tests around Keep-Fd ordering | Julian Andres Klode | 2025-10-20 | 1 | -0/+7 |
| | | |||||
| * | ExecFork: Use close_range() if available | Julian Andres Klode | 2025-10-20 | 1 | -0/+25 |
| Use close_range() if we have it in preference to iterating over /proc/self/fd and falling back to closing all possible fds. This builds sets of ranges to close that take into account the APT::Keep-Fds vector, and a test case is provided to ensure correctness of the splitting logic. Preference is given to close_range() over /proc as in the optimal case, this results in a single system call! | |||||
