From: <lab...@us...> - 2013-03-17 15:06:36
|
Revision: 1487 http://opengtoolkit.svn.sourceforge.net/opengtoolkit/?rev=1487&view=rev Author: labviewer Date: 2013-03-17 15:06:30 +0000 (Sun, 17 Mar 2013) Log Message: ----------- various minor edits Modified Paths: -------------- trunk/lvzip/c_source/Makefile.vxworks trunk/lvzip/c_source/gzread.c trunk/lvzip/c_source/inflate.c trunk/lvzip/c_source/ioapi.h trunk/lvzip/c_source/iomem.h trunk/lvzip/c_source/mztools.c trunk/lvzip/c_source/unzip.c trunk/lvzip/c_source/zip.h Modified: trunk/lvzip/c_source/Makefile.vxworks =================================================================== --- trunk/lvzip/c_source/Makefile.vxworks 2013-03-17 15:01:38 UTC (rev 1486) +++ trunk/lvzip/c_source/Makefile.vxworks 2013-03-17 15:06:30 UTC (rev 1487) @@ -19,10 +19,10 @@ # directory. Make will automatically locate the source file and # compile it. OBJECTS := $(OBJ_DIR)/adler32.o $(OBJ_DIR)/compress.o $(OBJ_DIR)/crc32.o $(OBJ_DIR)/deflate.o \ - $(OBJ_DIR)\gzclose.o $(OBJ_DIR)\gzlib.o $(OBJ_DIR)\gzread.o $(OBJ_DIR)\gzwrite.o \ + $(OBJ_DIR)/gzclose.o $(OBJ_DIR)/gzlib.o $(OBJ_DIR)/gzread.o $(OBJ_DIR)/gzwrite.o \ $(OBJ_DIR)/inffast.o $(OBJ_DIR)/infback.o $(OBJ_DIR)/inflate.o $(OBJ_DIR)/inftrees.o \ $(OBJ_DIR)/ioapi.o $(OBJ_DIR)/iomem.o $(OBJ_DIR)/lvutil.o $(OBJ_DIR)/lvapi.o $(OBJ_DIR)/mztools.o \ - $(OBJ_DIR)/trees.o $(OBJ_DIR)/uncompr.o $(OBJ_DIR)/unzip.o $(OBJ_DIR)/zip.o $(OBJ_DIR)/zutil.o + $(OBJ_DIR)/trees.o $(OBJ_DIR)/uncompr.o $(OBJ_DIR)/unzip.o $(OBJ_DIR)/zip.o $(OBJ_DIR)/zutil.o # This is the name of the output shared library. PROJECT_TARGETS := $(OBJ_DIR)/lvzlib.out @@ -50,11 +50,11 @@ # copy this rule and modify its extension and compile flags for the # required source file type. $(OBJ_DIR)/%.o : %.c - ccppc $(CFLAGS) $(CC_ARCH_SPEC) -Wall -MD -MP $(ADDED_CFLAGS) $(IDE_INCLUDES) $(ADDED_INCLUDES) -DCPU=$(CPU) -DTOOL_FAMILY=$(TOOL_FAMILY) -DTOOL=$(TOOL) -D_WRS_KERNEL $(DEFINES) -o "$@" -c "$<" + ccppc $(CFLAGS) $(CC_ARCH_SPEC) -Wall -MD -MP $(ADDED_CFLAGS) $(IDE_INCLUDES) $(ADDED_INCLUDES) -DCPU=$(CPU) -DTOOL_FAMILY=$(TOOL_FAMILY) -DTOOL=$(TOOL) -D_WRS_KERNEL $(DEFINES) -o "$@" -c "$<" # Adapted rule for .cpp files $(OBJ_DIR)/%.o : %.cpp - c++ppc $(CFLAGS) $(CC_ARCH_SPEC) -Wall -MD -MP $(ADDED_CFLAGS) $(IDE_INCLUDES) $(ADDED_INCLUDES) -DCPU=$(CPU) -DTOOL_FAMILY=$(TOOL_FAMILY) -DTOOL=$(TOOL) -D_WRS_KERNEL $(DEFINES) -o "$@" -c "$<" + c++ppc $(CFLAGS) $(CC_ARCH_SPEC) -Wall -MD -MP $(ADDED_CFLAGS) $(IDE_INCLUDES) $(ADDED_INCLUDES) -DCPU=$(CPU) -DTOOL_FAMILY=$(TOOL_FAMILY) -DTOOL=$(TOOL) -D_WRS_KERNEL $(DEFINES) -o "$@" -c "$<" all : check_objectdir $(PROJECT_TARGETS) Modified: trunk/lvzip/c_source/gzread.c =================================================================== --- trunk/lvzip/c_source/gzread.c 2013-03-17 15:01:38 UTC (rev 1486) +++ trunk/lvzip/c_source/gzread.c 2013-03-17 15:06:30 UTC (rev 1487) @@ -378,7 +378,6 @@ } /* -- see zlib.h -- */ -//#undef gzgetc int ZEXPORT gzgetc(file) gzFile file; { Modified: trunk/lvzip/c_source/inflate.c =================================================================== --- trunk/lvzip/c_source/inflate.c 2013-03-17 15:01:38 UTC (rev 1486) +++ trunk/lvzip/c_source/inflate.c 2013-03-17 15:06:30 UTC (rev 1487) @@ -429,10 +429,10 @@ /* check function to use adler32() for zlib or crc32() for gzip */ #ifdef GUNZIP -# define UPDATE(check, buf, len) \ +# define UPDATE_CHECK(check, buf, len) \ (state->flags ? crc32(check, buf, len) : adler32(check, buf, len)) #else -# define UPDATE(check, buf, len) adler32(check, buf, len) +# define UPDATE_CHECK(check, buf, len) adler32(check, buf, len) #endif /* check macros for header crc */ @@ -1178,7 +1178,7 @@ state->total += out; if (out) strm->adler = state->check = - UPDATE(state->check, put - out, out); + UPDATE_CHECK(state->check, put - out, out); out = left; if (( #ifdef GUNZIP @@ -1241,7 +1241,7 @@ state->total += out; if (state->wrap && out) strm->adler = state->check = - UPDATE(state->check, strm->next_out - out, out); + UPDATE_CHECK(state->check, strm->next_out - out, out); strm->data_type = state->bits + (state->last ? 64 : 0) + (state->mode == TYPE ? 128 : 0) + (state->mode == LEN_ || state->mode == COPY_ ? 256 : 0); Modified: trunk/lvzip/c_source/ioapi.h =================================================================== --- trunk/lvzip/c_source/ioapi.h 2013-03-17 15:01:38 UTC (rev 1486) +++ trunk/lvzip/c_source/ioapi.h 2013-03-17 15:06:30 UTC (rev 1487) @@ -23,8 +23,8 @@ #if (!defined(_WIN32)) && (!defined(WIN32)) && (!defined(__APPLE__)) - // Linux needs this to support file operation on files larger then 4+GB - // But might need better if/def to select just the platforms that needs them. + /* Linux needs this to support file operation on files larger then 4+GB + But might need better if/def to select just the platforms that needs them. */ #ifndef __USE_FILE_OFFSET64 #define __USE_FILE_OFFSET64 @@ -186,8 +186,8 @@ #define ZREAD64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zread_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) #define ZWRITE64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zwrite_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) -//#define ZTELL64(filefunc,filestream) ((*((filefunc).ztell64_file)) ((filefunc).opaque,filestream)) -//#define ZSEEK64(filefunc,filestream,pos,mode) ((*((filefunc).zseek64_file)) ((filefunc).opaque,filestream,pos,mode)) +/*#define ZTELL64(filefunc,filestream) ((*((filefunc).ztell64_file)) ((filefunc).opaque,filestream))*/ +/*#define ZSEEK64(filefunc,filestream,pos,mode) ((*((filefunc).zseek64_file)) ((filefunc).opaque,filestream,pos,mode))*/ #define ZCLOSE64(filefunc,filestream, output) ((*((filefunc).zfile_func64.zclose_file)) ((filefunc).zfile_func64.opaque,filestream,output)) #define ZERROR64(filefunc,filestream) ((*((filefunc).zfile_func64.zerror_file)) ((filefunc).zfile_func64.opaque,filestream)) Modified: trunk/lvzip/c_source/iomem.h =================================================================== --- trunk/lvzip/c_source/iomem.h 2013-03-17 15:01:38 UTC (rev 1486) +++ trunk/lvzip/c_source/iomem.h 2013-03-17 15:06:30 UTC (rev 1487) @@ -9,7 +9,7 @@ extern "C" { #endif -void fill_mem_filefunc OF((zlib_filefunc64_def* pzlib_filefunc_def, LStrHandle *memory)); +void fill_mem_filefunc(zlib_filefunc64_def* pzlib_filefunc_def, LStrHandle *memory); #ifdef __cplusplus } Modified: trunk/lvzip/c_source/mztools.c =================================================================== --- trunk/lvzip/c_source/mztools.c 2013-03-17 15:01:38 UTC (rev 1486) +++ trunk/lvzip/c_source/mztools.c 2013-03-17 15:06:30 UTC (rev 1487) @@ -222,7 +222,7 @@ { int entriesZip = entries; char header[22]; - char* comment = ""; // "ZIP File recovered by zlib/minizip/mztools"; + char* comment = ""; /* "ZIP File recovered by zlib/minizip/mztools" */ int comsize = (int) strlen(comment); if (entriesZip > 0xffff) { entriesZip = 0xffff; Modified: trunk/lvzip/c_source/unzip.c =================================================================== --- trunk/lvzip/c_source/unzip.c 2013-03-17 15:01:38 UTC (rev 1486) +++ trunk/lvzip/c_source/unzip.c 2013-03-17 15:06:30 UTC (rev 1487) @@ -956,7 +956,7 @@ if (unz64local_getLong(&s->z_filefunc, s->filestream,&file_info.external_fa) != UNZ_OK) err=UNZ_ERRNO; - // relative offset of local header + /* relative offset of local header */ if (unz64local_getLong(&s->z_filefunc, s->filestream,&uL) != UNZ_OK) err=UNZ_ERRNO; file_info_internal.offset_curfile = uL; @@ -979,7 +979,7 @@ lSeek -= uSizeRead; } - // Read extrafield + /* Read extrafield */ if ((err==UNZ_OK) && (extraField!=NULL)) { ZPOS64_T uSizeRead ; @@ -1010,7 +1010,7 @@ { uLong acc = 0; - // since lSeek now points to after the extra field we need to move back + /* since lSeek now points to after the extra field we need to move back */ lSeek -= file_info.size_file_extra; if (lSeek!=0) @@ -1627,6 +1627,7 @@ zdecode(s->keys,s->pcrc_32_tab,source[i]); s->pfile_in_zip_read->pos_in_zipfile+=12; + pfile_in_zip_read_info->rest_read_compressed -= 12; s->encrypted=1; } # endif Modified: trunk/lvzip/c_source/zip.h =================================================================== --- trunk/lvzip/c_source/zip.h 2013-03-17 15:01:38 UTC (rev 1486) +++ trunk/lvzip/c_source/zip.h 2013-03-17 15:06:30 UTC (rev 1487) @@ -44,7 +44,7 @@ ZEXTERN "C" { #endif -//#define HAVE_BZIP2 +/*#define HAVE_BZIP2*/ #ifndef _ZLIB_H #include "zlib.h" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |