1
0
mirror of https://github.com/django/django.git synced 2025-10-31 09:41:08 +00:00

Fixed #599 -- locmem cache now uses deepcopy() to prevent aliasing. Thanks, Hugo

git-svn-id: http://code.djangoproject.com/svn/django/trunk@821 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Adrian Holovaty
2005-10-10 13:56:39 +00:00
parent f258a8fce2
commit b4e2d12b1f
2 changed files with 34 additions and 40 deletions

View File

@@ -1,4 +1,3 @@
import copy
from django.conf import settings
from django.core.cache import cache
from django.utils.cache import get_cache_key, learn_cache_key, patch_response_headers
@@ -49,7 +48,7 @@ class CacheMiddleware:
return None # No cache information available, need to rebuild.
request._cache_update_cache = False
return copy.copy(response)
return response
def process_response(self, request, response):
"Sets the cache, if needed."