From 9141a7bbca2ddcf2cb769802f3d9f21eb76d785a Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Wed, 9 May 2007 13:09:09 +0000 Subject: [PATCH] compat fix for older inotify versions git-svn-id: file:///home/lennart/svn/public/avahi/trunk@1470 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- avahi-daemon/main.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/avahi-daemon/main.c b/avahi-daemon/main.c index d994392..9f55473 100644 --- a/avahi-daemon/main.c +++ b/avahi-daemon/main.c @@ -677,8 +677,16 @@ static void add_inotify_watches(void) { c = config.use_chroot; #endif - inotify_add_watch(inotify_fd, c ? "/services" : AVAHI_SERVICE_DIR, IN_CLOSE_WRITE|IN_DELETE|IN_DELETE_SELF|IN_MOVED_FROM|IN_MOVED_TO|IN_MOVE_SELF|IN_ONLYDIR); - inotify_add_watch(inotify_fd, c ? "/" : AVAHI_CONFIG_DIR, IN_CLOSE_WRITE|IN_DELETE|IN_DELETE_SELF|IN_MOVED_FROM|IN_MOVED_TO|IN_MOVE_SELF|IN_ONLYDIR); + inotify_add_watch(inotify_fd, c ? "/services" : AVAHI_SERVICE_DIR, IN_CLOSE_WRITE|IN_DELETE|IN_DELETE_SELF|IN_MOVED_FROM|IN_MOVED_TO|IN_MOVE_SELF +#ifdef IN_ONLYDIR + |IN_ONLYDIR +#endif + ); + inotify_add_watch(inotify_fd, c ? "/" : AVAHI_CONFIG_DIR, IN_CLOSE_WRITE|IN_DELETE|IN_DELETE_SELF|IN_MOVED_FROM|IN_MOVED_TO|IN_MOVE_SELF +#ifdef IN_ONLYDIR + |IN_ONLYDIR +#endif + ); } #endif -- 2.39.5