copy of Go stdlib net/http/cgi with logging of unclean child process exits