Backport from master of bug fixes in wsgi.server and wsgidev.