Crash slightly more controlled under weird circumstances...
Wait for parent to release sockets (fixes #267, fixes #241)