[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: filenotify.el
From: |
Stefan Monnier |
Subject: |
Re: filenotify.el |
Date: |
Wed, 26 Jun 2013 10:28:24 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) |
> Imagine there are two registered watchers:
> (gfile-add-watch "/tmp" flags1 'callback1)
> (inotify-add-watch "/tmp" flags2 'callback2)
> Both return the same descriptor, let's say 1. What would you call, when
> there is an incoming event (1 flag "123") for the file "/tmp/123"?
Who's "you"? IIUC it's the C code, so if the C code calls inotify's
callback when receiving gfile's event it's a bug in the C code that
needs fixing regardless of filenotify.el.
>>> Such an event looks like (DESCRIPTOR ACTION FILE). Different low-level
>>> packages must use unique DESCRIPTORs then.
>> Just use (inotify DESCRIPTOR ACTION FILE) instead, if that's really needed.
> I would make the descriptor a cons cell '(inotify . number), but it is
> the same idea.
I don't see any need to make any change to the Elisp visible behavior.
> Again, for Tramp I use already a vector as descriptor.
> The only promise we have given is, that descriptors returned by
> *-add-watch functions can be distinguished via `equal'.
Also that a callback is only called for those events on which it
was added.
Stefan
- Re: filenotify.el, (continued)
- Re: filenotify.el, Stefan Monnier, 2013/06/25
- Re: filenotify.el, Michael Albinus, 2013/06/26
- Re: filenotify.el, Stefan Monnier, 2013/06/26
- Re: filenotify.el, Michael Albinus, 2013/06/26
- Re: filenotify.el,
Stefan Monnier <=
- Re: filenotify.el, Michael Albinus, 2013/06/26
- Re: filenotify.el, Eli Zaretskii, 2013/06/26
- Re: filenotify.el, Stefan Monnier, 2013/06/26
- Re: filenotify.el, Michael Albinus, 2013/06/26
- Re: filenotify.el, RĂ¼diger Sonderfeld, 2013/06/25
- Re: filenotify.el, Michael Albinus, 2013/06/26
- About `<prefix>--' (was Re: filenotify.el), Stephen Berman, 2013/06/26
- Re: About `<prefix>--' (was Re: filenotify.el), Stefan Monnier, 2013/06/26
- Re: About `<prefix>--' (was Re: filenotify.el), Stephen Berman, 2013/06/26
- Re: About `<prefix>--' (was Re: filenotify.el), Stefan Monnier, 2013/06/26