Commit cc99508b authored by Jeremy Hylton's avatar Jeremy Hylton

Minor optimization and normalization -- wait/waiting.

parent 7dd92633
...@@ -288,7 +288,6 @@ class ClientStorage: ...@@ -288,7 +288,6 @@ class ClientStorage:
self._oid = '\0\0\0\0\0\0\0\0' self._oid = '\0\0\0\0\0\0\0\0'
# Decide whether to use non-temporary files # Decide whether to use non-temporary files
client = client
self._cache = self.ClientCacheClass(storage, cache_size, self._cache = self.ClientCacheClass(storage, cache_size,
client=client, var=var) client=client, var=var)
...@@ -321,7 +320,7 @@ class ClientStorage: ...@@ -321,7 +320,7 @@ class ClientStorage:
self._ready.wait(30) self._ready.wait(30)
if self._ready.isSet(): if self._ready.isSet():
break break
log2(INFO, "Wait for cache verification to finish") log2(INFO, "Waiting for cache verification to finish")
else: else:
self._wait_sync() self._wait_sync()
...@@ -331,7 +330,7 @@ class ClientStorage: ...@@ -331,7 +330,7 @@ class ClientStorage:
while 1: while 1:
if self._ready.isSet(): if self._ready.isSet():
break break
log2(INFO, "Wait for cache verification to finish") log2(INFO, "Waiting for cache verification to finish")
if self._connection is None: if self._connection is None:
# If the connection was closed while we were # If the connection was closed while we were
# waiting for it to become ready, start over. # waiting for it to become ready, start over.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment