apply patch from adiroiban. refs #7229

git-svn-id: svn://svn.twistedmatrix.com/svn/Twisted/branches/travis-ci-7229@43349 bbbe8e31-12d6-0310-92fd-ac37d47ddeeb