Thanks metzen for the report and initial patch, and Łukasz Rekucki for an inspirational patch on his randomhash_fixes branch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16616 bcc190cf-cafb-0310-a4f2-bffc1f526a37