[kupfer] core: Use weakref in PeriodicRescanner
- From: Ulrik Sverdrup <usverdrup src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [kupfer] core: Use weakref in PeriodicRescanner
- Date: Sun, 9 May 2010 15:55:38 +0000 (UTC)
commit e9f739592006cff15ef9cc9b178d9ef443e9803b
Author: Ulrik Sverdrup <ulrik sverdrup gmail com>
Date: Sun May 9 16:25:25 2010 +0100
core: Use weakref in PeriodicRescanner
kupfer/core/sources.py | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/kupfer/core/sources.py b/kupfer/core/sources.py
index e734901..021c579 100644
--- a/kupfer/core/sources.py
+++ b/kupfer/core/sources.py
@@ -30,7 +30,7 @@ class PeriodicRescanner (pretty.OutputMixin):
self.campaign=campaign
self.timer = scheduler.Timer()
# Source -> time mapping
- self.latest_rescan_time = {}
+ self.latest_rescan_time = weakref.WeakKeyDictionary()
self._min_rescan_interval = campaign//4
def set_catalog(self, catalog):
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]