summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cat.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/cat.c b/cat.c
index 6f8ea55..3345bf2 100644
--- a/cat.c
+++ b/cat.c
@@ -12,7 +12,7 @@
void cat(int fd, char * name)
{
char buffer[4096];
- size_t length;
+ ssize_t length;
while (0 < (length=read(fd, buffer, sizeof(buffer))))
if (length != write(1, buffer, length))
panic("write: %s: %s", name, strerror(errno));