summaryrefslogtreecommitdiff
path: root/klm/util/file_piece.hh
diff options
context:
space:
mode:
authorKenneth Heafield <github@kheafield.com>2012-05-28 12:29:05 -0400
committerKenneth Heafield <github@kheafield.com>2012-05-28 12:29:05 -0400
commit84b2894b639aa7de689a75dad8077639cbb03879 (patch)
treea42561873eb4f1b62ecaeb45bcd1cc999e62373a /klm/util/file_piece.hh
parent0af4919f399d009ca8bcb9cadefbcc148c174c20 (diff)
Fix FilePiece gzip
Diffstat (limited to 'klm/util/file_piece.hh')
-rw-r--r--klm/util/file_piece.hh10
1 files changed, 8 insertions, 2 deletions
diff --git a/klm/util/file_piece.hh b/klm/util/file_piece.hh
index b81ac0e2..af93d8aa 100644
--- a/klm/util/file_piece.hh
+++ b/klm/util/file_piece.hh
@@ -13,6 +13,10 @@
#include <stdint.h>
+#ifdef HAVE_ZLIB
+#include <zlib.h>
+#endif
+
namespace util {
class ParseNumberException : public Exception {
@@ -23,7 +27,9 @@ class ParseNumberException : public Exception {
class GZException : public Exception {
public:
- explicit GZException(void *file);
+#ifdef HAVE_ZLIB
+ explicit GZException(gzFile file);
+#endif
GZException() throw() {}
~GZException() throw() {}
};
@@ -117,7 +123,7 @@ class FilePiece {
std::string file_name_;
#ifdef HAVE_ZLIB
- void *gz_file_;
+ gzFile gz_file_;
#endif // HAVE_ZLIB
};