diff options
author | Ron Yorston <rmy@pobox.com> | 2012-03-22 16:14:13 +0000 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2012-03-22 16:14:13 +0000 |
commit | 800c3f176fb21e30fbaa81ef68f50e601ea2f78b (patch) | |
tree | 84f4a2bf30d3208a020b25c82c11ac636c7072c6 /coreutils | |
parent | 9db164d6e39050d09f38288c6045cd2a2cbf6d63 (diff) | |
parent | f99811908419608e3ab81393d0177cc456101e4b (diff) | |
download | busybox-w32-800c3f176fb21e30fbaa81ef68f50e601ea2f78b.tar.gz busybox-w32-800c3f176fb21e30fbaa81ef68f50e601ea2f78b.tar.bz2 busybox-w32-800c3f176fb21e30fbaa81ef68f50e601ea2f78b.zip |
Merge commit '1_19_4' into merge_1_19
Diffstat (limited to 'coreutils')
-rw-r--r-- | coreutils/tail.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/coreutils/tail.c b/coreutils/tail.c index 454c25936..43cecbd97 100644 --- a/coreutils/tail.c +++ b/coreutils/tail.c | |||
@@ -203,7 +203,7 @@ int tail_main(int argc, char **argv) | |||
203 | int fd = fds[i]; | 203 | int fd = fds[i]; |
204 | 204 | ||
205 | if (ENABLE_FEATURE_FANCY_TAIL && fd < 0) | 205 | if (ENABLE_FEATURE_FANCY_TAIL && fd < 0) |
206 | continue; /* may happen with -E */ | 206 | continue; /* may happen with -F */ |
207 | 207 | ||
208 | if (nfiles > header_threshhold) { | 208 | if (nfiles > header_threshhold) { |
209 | tail_xprint_header(fmt, argv[i]); | 209 | tail_xprint_header(fmt, argv[i]); |
@@ -252,14 +252,14 @@ int tail_main(int argc, char **argv) | |||
252 | * Used only by +N code ("start from Nth", 1-based): */ | 252 | * Used only by +N code ("start from Nth", 1-based): */ |
253 | seen = 1; | 253 | seen = 1; |
254 | newlines_seen = 0; | 254 | newlines_seen = 0; |
255 | while ((nread = tail_read(fd, buf, tailbufsize-taillen)) > 0) { | 255 | while ((nread = tail_read(fd, buf, tailbufsize - taillen)) > 0) { |
256 | if (G.from_top) { | 256 | if (G.from_top) { |
257 | int nwrite = nread; | 257 | int nwrite = nread; |
258 | if (seen < count) { | 258 | if (seen < count) { |
259 | /* We need to skip a few more bytes/lines */ | 259 | /* We need to skip a few more bytes/lines */ |
260 | if (COUNT_BYTES) { | 260 | if (COUNT_BYTES) { |
261 | nwrite -= (count - seen); | 261 | nwrite -= (count - seen); |
262 | seen = count; | 262 | seen += nread; |
263 | } else { | 263 | } else { |
264 | char *s = buf; | 264 | char *s = buf; |
265 | do { | 265 | do { |