src/share/native/java/util/zip/zip_util.h

Print this page

        

*** 43,55 **** /* * Header sizes including signatures */ - #ifdef USE_MMAP - #define SIGSIZ 4 - #endif #define LOCHDR 30 #define EXTHDR 16 #define CENHDR 46 #define ENDHDR 22 --- 43,52 ----
*** 209,221 **** #ifdef USE_MMAP unsigned char *maddr; /* beginning address of the CEN & ENDHDR */ jlong mlen; /* length (in bytes) mmaped */ jlong offset; /* offset of the mmapped region from the start of the file. */ ! #else ! cencache cencache; /* CEN header cache */ #endif ZFILE zfd; /* open file descriptor */ void *lock; /* read lock */ char *comment; /* zip file comment */ jint clen; /* length of the zip file comment */ char *msg; /* zip error message */ --- 206,218 ---- #ifdef USE_MMAP unsigned char *maddr; /* beginning address of the CEN & ENDHDR */ jlong mlen; /* length (in bytes) mmaped */ jlong offset; /* offset of the mmapped region from the start of the file. */ ! jboolean usemmap; /* if mmap is used. */ #endif + cencache cencache; /* CEN header cache */ ZFILE zfd; /* open file descriptor */ void *lock; /* read lock */ char *comment; /* zip file comment */ jint clen; /* length of the zip file comment */ char *msg; /* zip error message */
*** 257,266 **** --- 254,266 ---- ZIP_Get_From_Cache(const char *name, char **pmsg, jlong lastModified); jzfile * ZIP_Put_In_Cache(const char *name, ZFILE zfd, char **pmsg, jlong lastModified); + jzfile * + ZIP_Put_In_Cache0(const char *name, ZFILE zfd, char **pmsg, jlong lastModified, jboolean usemmap); + void JNICALL ZIP_Close(jzfile *zip); jzentry * ZIP_GetEntry(jzfile *zip, char *name, jint ulen); void ZIP_Lock(jzfile *zip);