saltstack/salt — pull request #4022 by s0undt3ch (2013-03-09 14:23:14+00:00)
Title: Try to handle `SIGCHLD` as best as we can under python 2.6. Fixes #4008.

* We do some try/except "magic" to see if we import a safe `subprocess` module on `salt.utils.process`.
* If we're running under python 2.6, we try to import `subprocess32` which properly handles our problem.
* If the above step fails, we import the build-in `subprocess` module.
* We also define `SAFELY_HANDLE_SIGCHLD` on `salt.utils.process` so we can know if we need to reset the `SIGCHLD` handler on `salt.modules.cmdmod` so the know bug is not triggered, again, under python 2.6

For some additional info, see:
* #4008
* http://bugs.python.org/issue912
* http://bugs.python.org/issue1731717