diff options
author | Tobias Klauser <tklauser@distanz.ch> | 2006-09-03 17:44:02 +0200 |
---|---|---|
committer | Tobias Klauser <tklauser@xenon.tklauser.home> | 2006-09-03 17:44:02 +0200 |
commit | f43feddebbcfe819879786328e1768793c6842b7 (patch) | |
tree | b20a089f1a61bbf4b402a855b6d1c1f255c99b41 | |
parent | 6323755c60ee7173158279d8a442c1cad96263d0 (diff) |
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
-rw-r--r-- | inotail.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -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; |