summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--inotail.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/inotail.c b/inotail.c
index fcf9185..aa11a8c 100644
--- a/inotail.c
+++ b/inotail.c
@@ -105,8 +105,10 @@ static void ignore_file(struct file_struct *f)
close(f->fd);
f->fd = -1;
}
- f->ignore = 1;
- n_ignored++;
+ if (!f->ignore) {
+ f->ignore = 1;
+ n_ignored++;
+ }
}
static inline char *pretty_name(char *filename)