bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#21432: 25.0.50; file-notify-rm-watch (inotify) errors if watched dir


From: Michael Albinus
Subject: bug#21432: 25.0.50; file-notify-rm-watch (inotify) errors if watched dir is deleted
Date: Tue, 08 Sep 2015 09:47:07 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

Tassilo Horn <tsdh@gnu.org> writes:

Hi Tassilo,

> I don't have a strong opinion about what the right behavior would be but
> at least it seems inconsistent that you get the error only with deleted
> directories.  I guess the best solution was if `file-notify-rm-watch'
> never signaled an error (then the docs can stay as they are), and there
> would be some `file-notify-valid-p' predicate which would test if a
> given descriptor still denotes a valid file or directory.  I guess the
> latter has probably some function equivalent in the respective backend
> APIs, and even if not, it can be implemented by inspecting
> `file-notify-descriptors'.

`file-notify-rm-watch' is just a cleanup function, it's not worth to add
some error handling. I will wrap the call of the native handlers by
catching `file-notify-error'. Alternatively, `inotify-rm-watch' could be
adapted not to raise an error in this case.

`file-notify-valid-p' is a nice idea; I will see how I could add it. At
least for the w32 case I would need some help from Eli, in order to
see whether the native library supports such a check.

Best regards, Michael.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]