From 840420f4014e03318d4258f934110ddb11c11942 Mon Sep 17 00:00:00 2001 From: Ben Longbons Date: Fri, 30 Sep 2011 17:50:31 -0700 Subject: Fix abuse of fread. --- src/common/grfio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/common/grfio.c b/src/common/grfio.c index 5e03b7c..d640263 100644 --- a/src/common/grfio.c +++ b/src/common/grfio.c @@ -201,7 +201,7 @@ void *grfio_reads (const char *fname, size_t *size) } uint8_t *buf2; CREATE (buf2, uint8_t, lentry.declen + 1024); - if (!fread (buf2, 1, lentry.declen, in)) + if (fread (buf2, 1, lentry.declen, in) != lentry.declen) exit(1); fclose_ (in); in = NULL; -- cgit v1.2.3-60-g2f50