summaryrefslogtreecommitdiff
path: root/src/tail.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1994-11-01 22:21:23 +0000
committerJim Meyering <jim@meyering.net>1994-11-01 22:21:23 +0000
commit7a5462a0b71b8b6bfe5f71cad341f2a149aa0535 (patch)
tree696be0fc2fa9c3a9364997fd0556dca7daad3b2c /src/tail.c
parentca83b5d1745d4750a5154fb1a057709157440e19 (diff)
downloadcoreutils-7a5462a0b71b8b6bfe5f71cad341f2a149aa0535.tar.xz
(XWRITE): Allow n_bytes to be zero in assertion. Otherwise `tail /dev/null'
gets failed assertion.
Diffstat (limited to 'src/tail.c')
-rw-r--r--src/tail.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/tail.c b/src/tail.c
index 87983253c..138f93a0c 100644
--- a/src/tail.c
+++ b/src/tail.c
@@ -54,14 +54,14 @@
#include "system.h"
#include "version.h"
-/* FIXME: uncomment before release. */
-/* #define NDEBUG 1 */
+/* Disable assertions. Some systems have broken assert macros. */
+#define NDEBUG 1
#define XWRITE(fd, buffer, n_bytes) \
do \
{ \
assert ((fd) == 1); \
- assert ((n_bytes) > 0); \
+ assert ((n_bytes) >= 0); \
if (fwrite ((buffer), 1, (n_bytes), stdout) == 0) \
error (1, errno, "write error"); \
} \