projects
/
oweals
/
busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f9782ff
)
tailk: fix error detected by testsuite
author
Denys Vlasenko
<vda.linux@googlemail.com>
Fri, 12 Mar 2010 21:16:25 +0000
(22:16 +0100)
committer
Denys Vlasenko
<vda.linux@googlemail.com>
Fri, 12 Mar 2010 21:16:25 +0000
(22:16 +0100)
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
coreutils/tail.c
patch
|
blob
|
history
diff --git
a/coreutils/tail.c
b/coreutils/tail.c
index 83768d4208c54470f2c2f5bdd467d77719e0218f..8fc22f562eff7c8b98eb6e3e54591baeb7b697ff 100644
(file)
--- a/
coreutils/tail.c
+++ b/
coreutils/tail.c
@@
-241,7
+241,8
@@
int tail_main(int argc, char **argv)
} while (nwrite);
}
}
- xwrite(STDOUT_FILENO, buf + nread - nwrite, nwrite);
+ if (nwrite > 0)
+ xwrite(STDOUT_FILENO, buf + nread - nwrite, nwrite);
} else if (count) {
if (COUNT_BYTES) {
taillen += nread;