aboutsummaryrefslogtreecommitdiff
path: root/coreutils/tail.c
diff options
context:
space:
mode:
Diffstat (limited to 'coreutils/tail.c')
-rw-r--r--coreutils/tail.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/coreutils/tail.c b/coreutils/tail.c
index 52aa8f69e..35b25a416 100644
--- a/coreutils/tail.c
+++ b/coreutils/tail.c
@@ -87,7 +87,6 @@ int tail_main(int argc, char **argv)
87 bool from_top; 87 bool from_top;
88 int header_threshhold = 1; 88 int header_threshhold = 1;
89 const char *str_c, *str_n; 89 const char *str_c, *str_n;
90 USE_FEATURE_FANCY_TAIL(const char *str_s;)
91 90
92 char *tailbuf; 91 char *tailbuf;
93 size_t tailbufsize; 92 size_t tailbufsize;
@@ -110,8 +109,9 @@ int tail_main(int argc, char **argv)
110 } 109 }
111#endif 110#endif
112 111
112 USE_FEATURE_FANCY_TAIL(opt_complementary = "s+";) /* -s N */
113 opt = getopt32(argv, "fc:n:" USE_FEATURE_FANCY_TAIL("qs:v"), 113 opt = getopt32(argv, "fc:n:" USE_FEATURE_FANCY_TAIL("qs:v"),
114 &str_c, &str_n USE_FEATURE_FANCY_TAIL(,&str_s)); 114 &str_c, &str_n USE_FEATURE_FANCY_TAIL(,&sleep_period));
115#define FOLLOW (opt & 0x1) 115#define FOLLOW (opt & 0x1)
116#define COUNT_BYTES (opt & 0x2) 116#define COUNT_BYTES (opt & 0x2)
117 //if (opt & 0x1) // -f 117 //if (opt & 0x1) // -f
@@ -119,7 +119,6 @@ int tail_main(int argc, char **argv)
119 if (opt & 0x4) count = eat_num(str_n); // -n 119 if (opt & 0x4) count = eat_num(str_n); // -n
120#if ENABLE_FEATURE_FANCY_TAIL 120#if ENABLE_FEATURE_FANCY_TAIL
121 if (opt & 0x8) header_threshhold = INT_MAX; // -q 121 if (opt & 0x8) header_threshhold = INT_MAX; // -q
122 if (opt & 0x10) sleep_period = xatou(str_s); // -s
123 if (opt & 0x20) header_threshhold = 0; // -v 122 if (opt & 0x20) header_threshhold = 0; // -v
124#endif 123#endif
125 argc -= optind; 124 argc -= optind;