improve cleanup of shell adaptor tmp files

This might improve performance on MacOS specifically.
fix hanging waitpid on macos
Merge branch 'devel'
updated changelog