aboutsummaryrefslogtreecommitdiff
path: root/src/ootx_decoder.c
diff options
context:
space:
mode:
authorCNLohr <lohr85@gmail.com>2017-03-14 19:05:46 -0400
committerCNLohr <lohr85@gmail.com>2017-03-14 19:05:46 -0400
commit0a2550249f9523dca974a79b51b5a7358b5fb943 (patch)
tree73d8d1e652582ce9199f12d9b3b990c54acce9f8 /src/ootx_decoder.c
parentf1d9ab47020293d373cc20695234e3677ceacb7f (diff)
downloadlibsurvive-0a2550249f9523dca974a79b51b5a7358b5fb943.tar.gz
libsurvive-0a2550249f9523dca974a79b51b5a7358b5fb943.tar.bz2
Almost able to build on Windows.
Diffstat (limited to 'src/ootx_decoder.c')
-rw-r--r--src/ootx_decoder.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/ootx_decoder.c b/src/ootx_decoder.c
index e35c24d..f7a7938 100644
--- a/src/ootx_decoder.c
+++ b/src/ootx_decoder.c
@@ -6,10 +6,14 @@
#include <stdio.h>
#include <stdlib.h>
-#include <zlib.h>
#include <assert.h>
#include "ootx_decoder.h"
-//#include "crc32.h"
+
+#ifdef NOZLIB
+#include "crc32.h"
+#else
+#include <zlib.h>
+#endif
//char* fmt_str = "L Y HMD %d 5 1 206230 %d\n";
@@ -145,7 +149,7 @@ void ootx_pump_bit(ootx_decoder_context *ctx, uint8_t dbit) {
op.data = ctx->buffer+2;
op.crc32 = *(uint32_t*)(op.data+padded_length);
- uint32_t crc = crc32( 0L, Z_NULL, 0 );
+ uint32_t crc = crc32( 0L, 0 /*Z_NULL*/, 0 );
crc = crc32( crc, op.data,op.length);
if (crc != op.crc32) {