From f43feddebbcfe819879786328e1768793c6842b7 Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Sun, 3 Sep 2006 17:44:02 +0200 Subject: Set mode explicitely when -n command line is specified This prevents us from doing the wrong thing in such (very unlikely) cases: $ inotail -c 6 -n 6 file.txt --- inotail.c | 1 + 1 file changed, 1 insertion(+) diff --git a/inotail.c b/inotail.c index cba84c6..fc9fb7e 100644 --- a/inotail.c +++ b/inotail.c @@ -320,6 +320,7 @@ int main(int argc, char **argv) forever = 1; break; case 'n': + mode = M_LINES; n_lines = strtoul(argv[++opt], NULL, 0); if (n_lines < 0) n_lines = 0; -- cgit v1.2.3-54-g00ecf