[entropy.cache] catch AttributeError, variable can be None

This commit is contained in:
Fabio Erculiani
2010-05-07 17:10:58 +02:00
parent ff0af58109
commit e173c8084f
+5 -1
View File
@@ -152,7 +152,11 @@ class EntropyCacher(Singleton):
__alive becomes False.
"""
# make sure our set delay is respected
self.__cache_writer.set_delay(EntropyCacher.WRITEBACK_TIMEOUT)
try:
self.__cache_writer.set_delay(EntropyCacher.WRITEBACK_TIMEOUT)
except AttributeError:
# can be None
pass
while self.__alive or run_until_empty: