applying patch from multani, refs #7680

git-svn-id: svn://svn.twistedmatrix.com/svn/Twisted/branches/contentdecoderagent-test-stability-7680@43360 bbbe8e31-12d6-0310-92fd-ac37d47ddeeb