Author: jacob Date: 2009-04-01 12:05:19 -0500 (Wed, 01 Apr 2009) New Revision: 10333
Modified: django/trunk/django/core/cache/backends/locmem.py Log: Fixed #9644: fix a thread sync issue in the locmem cache. Thanks, mrts. Modified: django/trunk/django/core/cache/backends/locmem.py =================================================================== --- django/trunk/django/core/cache/backends/locmem.py 2009-04-01 17:02:32 UTC (rev 10332) +++ django/trunk/django/core/cache/backends/locmem.py 2009-04-01 17:05:19 UTC (rev 10333) @@ -58,8 +58,11 @@ self._lock.reader_leaves() self._lock.writer_enters() try: - del self._cache[key] - del self._expire_info[key] + try: + del self._cache[key] + del self._expire_info[key] + except KeyError: + pass return default finally: self._lock.writer_leaves() --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to django-updates@googlegroups.com To unsubscribe from this group, send email to django-updates+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-updates?hl=en -~----------~----~----~----~------~----~------~--~---