From ba088196f621f6df4abd4aec64ed7fd5a4cbbbf9 Mon Sep 17 00:00:00 2001 From: Arun Prakash Jana Date: Fri, 1 Feb 2019 08:51:22 +0530 Subject: Do not watch dir if entering in filter mode --- src/nnn.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/nnn.c') diff --git a/src/nnn.c b/src/nnn.c index 2fe18cf..9a8ea37 100644 --- a/src/nnn.c +++ b/src/nnn.c @@ -2830,10 +2830,11 @@ begin: populate(path, lastname); #ifdef LINUX_INOTIFY - if (inotify_wd == -1) + if (presel != FILTER && inotify_wd == -1) { inotify_wd = inotify_add_watch(inotify_fd, path, INOTIFY_MASK); + } #elif defined(BSD_KQUEUE) - if (event_fd == -1) { + if (presel != FILTER && event_fd == -1) { #if defined(O_EVTONLY) event_fd = open(path, O_EVTONLY); #else -- cgit v1.2.3-70-g09d2