I'm going to try and make a custom Popen implementation where children only inherit some handles.
Copied in some implementation from mozprocess - it is licensed under the Mozilla Public License, v. 2.0.
Updating to match the 2.7.6 implementation contract regarding to_close.