summaryrefslogtreecommitdiff
path: root/builds
diff options
context:
space:
mode:
authorWerner Lemberg <wl@gnu.org>2006-05-10 04:47:35 +0000
committerWerner Lemberg <wl@gnu.org>2006-05-10 04:47:35 +0000
commitb80d85fe9ed3b0cf96d03dcfd7d1e1f149c2b718 (patch)
treeaa7c95fea56ba6935d75afd2bc172984d7da9e09 /builds
parenta127ca42cadfefa9e71c1cd8a86cc3b9f3768633 (diff)
downloadfreetype2-b80d85fe9ed3b0cf96d03dcfd7d1e1f149c2b718.tar.gz
* builds/unix/ftsystem.c (FT_Stream_Open): Avoid infinite loop if
given an empty, un-mmap()able file. Reported and suggested fix in Savannah bug #16555.
Diffstat (limited to 'builds')
-rw-r--r--builds/unix/ftsystem.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builds/unix/ftsystem.c b/builds/unix/ftsystem.c
index 2253dbac4..78da9d575 100644
--- a/builds/unix/ftsystem.c
+++ b/builds/unix/ftsystem.c
@@ -303,7 +303,7 @@
stream->base + total_read_count,
stream->size - total_read_count );
- if ( ( read_count == -1 ) )
+ if ( ( read_count <= 0 ) )
{
if ( errno == EINTR )
continue;