[PATCH 6/6] server: Share more code between pipe lient and server destructors.