projects
/
tahoe-lafs
/
tahoe-lafs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c24f559
)
don't do callbacks if we don't have any
author
meejah
<meejah@meejah.ca>
Tue, 8 Dec 2015 16:24:05 +0000
(08:24 -0800)
committer
Daira Hopwood
<daira@jacaranda.org>
Thu, 14 Jan 2016 17:27:07 +0000
(17:27 +0000)
src/allmydata/windows/inotify.py
patch
|
blob
|
history
diff --git
a/src/allmydata/windows/inotify.py
b/src/allmydata/windows/inotify.py
index 4e7bc90492c9a263f5e9008cb0813816e762db96..71d0f34e6e11e3e3a7109bec5a9bfadbe382735a 100644
(file)
--- a/
src/allmydata/windows/inotify.py
+++ b/
src/allmydata/windows/inotify.py
@@
-272,11
+272,12
@@
class INotify(PollMixin):
self._pending.add(path)
def _do_callbacks():
self._pending.remove(path)
- for cb in self._callbacks:
- try:
- cb(None, path, IN_CHANGED)
- except Exception, e:
- log.err(e)
+ if self._callbacks:
+ for cb in self._callbacks:
+ try:
+ cb(None, path, IN_CHANGED)
+ except Exception, e:
+ log.err(e)
reactor.callLater(self._pending_delay, _do_callbacks)
reactor.callFromThread(_maybe_notify, path)
except Exception, e: