using two inotify sockets

Daniel Kahn Gillmor dkg at fifthhorseman.net
Mon Aug 7 09:23:35 CEST 2017


hey folks--

I've noticed that gpg-agent is now using two inotify sockets instead of
one, as of this commit:

1ead1ca818bddabc3bca22c195be667993eb3e2e

    agent: Shutdown on removal of the home directory.
    
    * common/sysutils.c (gnupg_inotify_watch_delete_self): New.
    * agent/gpg-agent.c (handle_connections): Rename my_inotify_fd to
    sock_inotify_fd.
    (handle_connections): Add home_inotify_fd to watch the home directory.
    --
    
    GnuPG-bug-id: 3218
    
    Note that we should add this also to dirmngr.  And for non-Linux
    systems a stat in ticker should be implemented.
    
    Signed-off-by: Werner Koch <wk at gnupg.org>


It's not clear to me what the advantage is of having two inotify sockets
instead of having a single inotify socket which is watching multiple
locations.

I'm inclined to write a patch to simplify it to use only one inotify
socket, but if there's a reason to use two that i'm unaware of i'd
rather hear about it before i make the changes.

       --dkg
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: </pipermail/attachments/20170807/b0b52c46/attachment.sig>


More information about the Gnupg-devel mailing list