From: Daira Hopwood Date: Tue, 22 Sep 2015 15:45:34 +0000 (+0100) Subject: Make sure that a path is in the pending set before calling Uploader._process on it. X-Git-Url: https://git.rkrishnan.org/?a=commitdiff_plain;h=3d4eb1b430aa26e7e67596519cdaefd2cbefa663;p=tahoe-lafs%2Ftahoe-lafs.git Make sure that a path is in the pending set before calling Uploader._process on it. Signed-off-by: Daira Hopwood --- diff --git a/src/allmydata/frontends/magic_folder.py b/src/allmydata/frontends/magic_folder.py index 7b40708f..59087ca0 100644 --- a/src/allmydata/frontends/magic_folder.py +++ b/src/allmydata/frontends/magic_folder.py @@ -248,6 +248,10 @@ class Uploader(QueueMixin): for child in children: assert isinstance(child, unicode), child d.addCallback(lambda ign, child=child: os.path.join(reldir_u, child)) + def _add_pending(relpath_u): + self._pending.add(relpath_u) + return relpath_u + d.addCallback(_add_pending) d.addCallback(self._process) d.addErrback(log.err)