summaryrefslogtreecommitdiffstats
path: root/generic/tclZipfs.c
diff options
context:
space:
mode:
Diffstat (limited to 'generic/tclZipfs.c')
-rw-r--r--generic/tclZipfs.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/generic/tclZipfs.c b/generic/tclZipfs.c
index afd3db5..c936a15 100644
--- a/generic/tclZipfs.c
+++ b/generic/tclZipfs.c
@@ -27,7 +27,6 @@
#define MAP_FILE 0
#endif /* !MAP_FILE */
#define NOBYFOUR
-#define crc32tab crc_table[0]
#ifndef TBLS
#define TBLS 1
#endif
@@ -75,6 +74,8 @@
#include "zutil.h"
#include "crc32.h"
+static const z_crc_t* crc32tab;
+
/*
** We are compiling as part of the core.
** TIP430 style zipfs prefix
@@ -1864,6 +1865,7 @@ ZipfsSetup(void)
Tcl_MutexUnlock(&ZipFSMutex);
#endif /* TCL_THREADS */
+ crc32tab = get_crc_table();
Tcl_FSRegister(NULL, &zipfsFilesystem);
Tcl_InitHashTable(&ZipFS.fileHash, TCL_STRING_KEYS);
Tcl_InitHashTable(&ZipFS.zipHash, TCL_STRING_KEYS);