Exemplo n.º 1
0
 def __init__(self):
     self.fd = libc.inotify_init1(IN_FLAGS)
     if self.fd == -1:
         raise OSError
     self.fh = os.fdopen(self.fd)
     debug("inotifyfd=%d" % self.inotifyfd)
     self.watchers = dict()
     self.buf = bytearray(self.buflen)