Show More
@@ -288,14 +288,6 b' class repowatcher(pollable):' | |||||
288 | self.add_watch(self.repo.path, inotify.IN_DELETE) |
|
288 | self.add_watch(self.repo.path, inotify.IN_DELETE) | |
289 | self.check_dirstate() |
|
289 | self.check_dirstate() | |
290 |
|
290 | |||
291 | def wpath(self, evt): |
|
|||
292 | path = evt.fullpath |
|
|||
293 | if path == self.repo.root: |
|
|||
294 | return '' |
|
|||
295 | if path.startswith(self.wprefix): |
|
|||
296 | return path[len(self.wprefix):] |
|
|||
297 | raise 'wtf? ' + path |
|
|||
298 |
|
||||
299 | def dir(self, tree, path): |
|
291 | def dir(self, tree, path): | |
300 | if path: |
|
292 | if path: | |
301 | for name in path.split('/'): |
|
293 | for name in path.split('/'): | |
@@ -585,7 +577,9 b' class repowatcher(pollable):' | |||||
585 | self.ui.note(_('%s reading %d events\n') % |
|
577 | self.ui.note(_('%s reading %d events\n') % | |
586 | (self.event_time(), len(events))) |
|
578 | (self.event_time(), len(events))) | |
587 | for evt in events: |
|
579 | for evt in events: | |
588 | wpath = self.wpath(evt) |
|
580 | assert evt.fullpath.startswith(self.wprefix) | |
|
581 | wpath = evt.fullpath[len(self.wprefix):] | |||
|
582 | ||||
589 | if evt.mask & inotify.IN_UNMOUNT: |
|
583 | if evt.mask & inotify.IN_UNMOUNT: | |
590 | self.process_unmount(wpath, evt) |
|
584 | self.process_unmount(wpath, evt) | |
591 | elif evt.mask & (inotify.IN_MODIFY | inotify.IN_ATTRIB): |
|
585 | elif evt.mask & (inotify.IN_MODIFY | inotify.IN_ATTRIB): |
General Comments 0
You need to be logged in to leave comments.
Login now