Comment by lgg

4 years ago

Not sure if it worth the platform specific code, but for #2 macOS 10.15+ has `posix_spawn_file_actions_addfchdir_np()`.

I think most of these are deficiencies in the available posix_spawn actions, not anything inherent. Of course getting all the relevant OSes to add new functionality is a huge pain. The error handling seems bad though.