summaryrefslogtreecommitdiff
path: root/python2/pyinotify.py
diff options
context:
space:
mode:
Diffstat (limited to 'python2/pyinotify.py')
-rwxr-xr-xpython2/pyinotify.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/python2/pyinotify.py b/python2/pyinotify.py
index 204e381..cb562c5 100755
--- a/python2/pyinotify.py
+++ b/python2/pyinotify.py
@@ -220,6 +220,14 @@ class _CtypesLibcINotifyWrapper(INotifyWrapper):
not hasattr(self._libc, 'inotify_add_watch') or
not hasattr(self._libc, 'inotify_rm_watch')):
return False
+
+ self._libc.inotify_init.argtypes = []
+ self._libc.inotify_init.restype = ctypes.c_int
+ self._libc.inotify_add_watch.argtypes = [ctypes.c_int, ctypes.c_char_p,
+ ctypes.c_uint32]
+ self._libc.inotify_add_watch.restype = ctypes.c_int
+ self._libc.inotify_rm_watch.argtypes = [ctypes.c_int, ctypes.c_int]
+ self._libc.inotify_rm_watch.restype = ctypes.c_int
return True
def _get_errno(self):