Wait on the child pid during the last step of Double

This avoids turning the child into a zombie.