From: Daira Hopwood <daira@jacaranda.org>
Date: Tue, 27 Oct 2015 21:38:03 +0000 (+0000)
Subject: Correct type for Windows BOOL.
X-Git-Url: https://git.rkrishnan.org/%5B/frontends/CLI.rst?a=commitdiff_plain;h=1a902da79686607bfe7c5930e7a0936230846bf1;p=tahoe-lafs%2Ftahoe-lafs.git

Correct type for Windows BOOL.

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

diff --git a/src/allmydata/windows/inotify.py b/src/allmydata/windows/inotify.py
index 29bf176e..bcbc241f 100644
--- a/src/allmydata/windows/inotify.py
+++ b/src/allmydata/windows/inotify.py
@@ -90,6 +90,8 @@ _action_to_inotify_mask = {
 
 INVALID_HANDLE_VALUE             = 0xFFFFFFFF
 
+TRUE  = 0
+FALSE = 1
 
 class Event(object):
     """
@@ -173,7 +175,7 @@ def _open_directory(path_u):
 def simple_test():
     path_u = u"test"
     filter = FILE_NOTIFY_CHANGE_FILE_NAME | FILE_NOTIFY_CHANGE_DIR_NAME | FILE_NOTIFY_CHANGE_LAST_WRITE
-    recursive = False
+    recursive = FALSE
 
     hDirectory = _open_directory(path_u)
     fni = FileNotifyInformation()
@@ -236,7 +238,7 @@ class INotify(PollMixin):
         if mask & IN_ATTRIB:
             self._filter = self._filter | FILE_NOTIFY_CHANGE_ATTRIBUTES | FILE_NOTIFY_CHANGE_SECURITY
 
-        self._recursive = recursive
+        self._recursive = TRUE if recursive else FALSE
         self._callbacks = callbacks or []
         self._hDirectory = _open_directory(path_u)