* src/gzip/ftgzip.c (FT_Stream_OpenGzip): Use real stream size.
diff --git a/ChangeLog b/ChangeLog
index a22466b..afd34e9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2015-10-09 Werner Lemberg <wl@gnu.org>
+
+ * src/gzip/ftgzip.c (FT_Stream_OpenGzip): Use real stream size.
+
2015-10-08 Werner Lemberg <wl@gnu.org>
[pcf] Protect against invalid number of TOC entries (#46159).
diff --git a/src/gzip/ftgzip.c b/src/gzip/ftgzip.c
index 422035c..27c6254 100644
--- a/src/gzip/ftgzip.c
+++ b/src/gzip/ftgzip.c
@@ -691,9 +691,13 @@
}
error = FT_Err_Ok;
}
+
+ if ( zip_size )
+ stream->size = zip_size;
+ else
+ stream->size = 0x7FFFFFFFL; /* don't know the real size! */
}
- stream->size = 0x7FFFFFFFL; /* don't know the real size! */
stream->pos = 0;
stream->base = NULL;
stream->read = ft_gzip_stream_io;