From: Daira Hopwood <daira@jacaranda.org>
Date: Mon, 20 Apr 2015 16:17:52 +0000 (+0100)
Subject: Add recursive=True to drop_upload watch.
X-Git-Url: https://git.rkrishnan.org/pf/module-simplejson.html?a=commitdiff_plain;h=c3b3fdf75053b34f19b61e3a710925b851de6d1a;p=tahoe-lafs%2Ftahoe-lafs.git

Add recursive=True to drop_upload watch.

Signed-off-by: Daira Hopwood <daira@jacaranda.org>
---

diff --git a/src/allmydata/frontends/drop_upload.py b/src/allmydata/frontends/drop_upload.py
index 78fee45e..bdf962c5 100644
--- a/src/allmydata/frontends/drop_upload.py
+++ b/src/allmydata/frontends/drop_upload.py
@@ -79,7 +79,8 @@ class DropUploader(service.MultiService):
         # be an IN_CLOSE_WRITE after an IN_CREATE (I think).
         # TODO: what about IN_MOVE_SELF or IN_UNMOUNT?
         mask = inotify.IN_CLOSE_WRITE | inotify.IN_MOVED_TO | inotify.IN_ONLYDIR
-        self._notifier.watch(self._local_path, mask=mask, callbacks=[self._notify], autoAdd=True)
+        self._notifier.watch(self._local_path, mask=mask, callbacks=[self._notify],
+                             autoAdd=True, recursive=True)
 
     def _check_db_file(self, childpath):
         # returns True if the file must be uploaded.