v0.53
This commit is contained in:
parent
4ce4e79316
commit
ebe22eeace
29 changed files with 11319 additions and 11678 deletions
10
UnAlz.cpp
10
UnAlz.cpp
|
@ -30,6 +30,10 @@
|
|||
# include <errno.h> // iconv.h ¶§¹®¿¡ ÇÊ¿ä
|
||||
#endif
|
||||
|
||||
#if defined(__NetBSD__)
|
||||
# include <sys/param.h> // __NetBSD_Version__
|
||||
# include <errno.h> // iconv.h ¶§¹®¿¡ ÇÊ¿ä
|
||||
#endif
|
||||
|
||||
#define swapint64(Data) (INT64) ( (((Data)&0x00000000000000FFLL) << 56) | (((Data)&0x000000000000FF00LL) << 40) | (((Data)&0x0000000000FF0000LL) << 24) | (((Data)&0x00000000FF000000LL) << 8) | (((Data)&0x000000FF00000000LL) >> 8) | (((Data)&0x0000FF0000000000LL) >> 24) | (((Data)&0x00FF000000000000LL) >> 40) | (((Data)&0xFF00000000000000LL) >> 56) )
|
||||
#define swapint32(a) ((((a)&0xff)<<24)+(((a>>8)&0xff)<<16)+(((a>>16)&0xff)<<8)+(((a>>24)&0xff)))
|
||||
|
@ -45,7 +49,7 @@
|
|||
inline UINT64 unalz_le64toh(UINT64 a){return a;}
|
||||
#endif
|
||||
|
||||
#ifdef __FreeBSD__
|
||||
#if defined(__FreeBSD__) || defined(__NetBSD__)
|
||||
# include <sys/endian.h>
|
||||
inline UINT16 unalz_le16toh(UINT16 a){return le16toh(a);}
|
||||
inline UINT32 unalz_le32toh(UINT32 a){return le32toh(a);}
|
||||
|
@ -401,6 +405,8 @@ BOOL CUnAlz::ReadLocalFileheader()
|
|||
return FALSE;
|
||||
}
|
||||
FRead(zipHeader.fileName, zipHeader.head.fileNameLength);
|
||||
if(zipHeader.head.fileNameLength > MAX_PATH - 5)
|
||||
zipHeader.head.fileNameLength = MAX_PATH - 5;
|
||||
zipHeader.fileName[zipHeader.head.fileNameLength] = (CHAR)NULL;
|
||||
|
||||
|
||||
|
@ -416,7 +422,7 @@ BOOL CUnAlz::ReadLocalFileheader()
|
|||
size_t size;
|
||||
char inbuf[ICONV_BUF_SIZE];
|
||||
char outbuf[ICONV_BUF_SIZE];
|
||||
#if defined(__FreeBSD__) || defined(__CYGWIN__) || defined(__APPLE__)
|
||||
#if defined(__FreeBSD__) || defined(__CYGWIN__) || defined(__APPLE__) || defined(__NetBSD__)
|
||||
const char *inptr = inbuf;
|
||||
#else
|
||||
char *inptr = inbuf;
|
||||
|
|
7
UnAlz.h
7
UnAlz.h
|
@ -70,6 +70,11 @@
|
|||
- unalz 0.51
|
||||
2005/07/27 - main() 에 setlocale() 추가
|
||||
- unalz 0.52
|
||||
2005/10/15 - NetBSD 에서 컴파일 되도록 수정 ( by minskim@bawi )
|
||||
- unalz 0.53
|
||||
2005/11/21 - 파일명 처리쪽에 있는 Buffer overflow 문제 수정 ( by Ulf Harnhammar <metaur@telia.com> )
|
||||
- unalz 0.54
|
||||
|
||||
|
||||
기능 :
|
||||
- alz 파일의 압축 해제 (deflate/변형 bzip2/raw)
|
||||
|
@ -176,7 +181,7 @@ namespace UNALZ
|
|||
# pragma pack(1)
|
||||
#endif
|
||||
|
||||
static const char UNALZ_VERSION[] = "CUnAlz0.52";
|
||||
static const char UNALZ_VERSION[] = "CUnAlz0.53";
|
||||
static const char UNALZ_COPYRIGHT[] = "Copyright(C) 2004-2005 by hardkoder ( http://www.kipple.pe.kr ) ";
|
||||
|
||||
enum {ENCR_HEADER_LEN=12}; // xf86
|
||||
|
|
5
main.cpp
5
main.cpp
|
@ -7,6 +7,7 @@
|
|||
#include <time.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <locale.h>
|
||||
#include "UnAlz.h"
|
||||
#include "UnAlzUtils.h"
|
||||
|
||||
|
@ -24,7 +25,9 @@ void Copyright()
|
|||
// printf("unalz v0.4 (2005/06/18) \n");
|
||||
// printf("unalz v0.5 (2005/07/09) \n");
|
||||
// printf("unalz v0.51 (2005/07/24) \n");
|
||||
printf("unalz v0.52 (2005/07/27) \n");
|
||||
// printf("unalz v0.52 (2005/07/27) \n");
|
||||
// printf("unalz v0.53 (2005/10/15) \n");
|
||||
printf("unalz v0.54 (2005/11/21) \n");
|
||||
printf("Copyright(C) 2004-2005 by hardkoder (http://www.kipple.pe.kr) \n");
|
||||
}
|
||||
|
||||
|
|
369
unalz.dev
369
unalz.dev
|
@ -1,369 +0,0 @@
|
|||
[Project]
|
||||
FileName=unalz.dev
|
||||
Name=unalz
|
||||
Ver=1
|
||||
IsCpp=1
|
||||
Type=1
|
||||
Compiler=-D__GNUWIN32__ -W -DWIN32 -DNDEBUG -D_CONSOLE -D_MBCS_@@_
|
||||
CppCompiler=-D__GNUWIN32__ -W -DWIN32 -DNDEBUG -D_CONSOLE -D_MBCS_@@_
|
||||
Includes=
|
||||
Linker=-lkernel32 -luser32 -lgdi32 -lwinspool -lcomdlg32 -ladvapi32 -lshell32 -lole32 -loleaut32 -luuid -lodbc32 -lodbccp32 -lkernel32 -luser32 -lgdi32 -lwinspool -lcomdlg32 -ladvapi32 -lshell32 -lole32 -loleaut32 -luuid -lodbc32 -lodbccp32_@@_
|
||||
Libs=
|
||||
UnitCount=29
|
||||
Folders=bzip2,main,unalz,zlib
|
||||
ObjFiles=
|
||||
PrivateResource=
|
||||
ResourceIncludes=
|
||||
MakeIncludes=
|
||||
Icon=
|
||||
ExeOutput=./bin/
|
||||
ObjectOutput=
|
||||
OverrideOutput=0
|
||||
OverrideOutputName=unalz.exe
|
||||
HostApplication=
|
||||
CommandLine=
|
||||
UseCustomMakefile=0
|
||||
CustomMakefile=
|
||||
IncludeVersionInfo=0
|
||||
SupportXPThemes=0
|
||||
CompilerSet=0
|
||||
CompilerSettings=0000000000000000000000
|
||||
|
||||
[Unit1]
|
||||
FileName=main.cpp
|
||||
Folder=main
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit2]
|
||||
FileName=UnAlz.cpp
|
||||
Folder=unalz
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit3]
|
||||
FileName=UnAlz.h
|
||||
Folder=unalz
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit4]
|
||||
FileName=UnAlzBz2decompress.c
|
||||
Folder=unalz
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit5]
|
||||
FileName=UnAlzBzip2.cpp
|
||||
Folder=unalz
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit6]
|
||||
FileName=UnAlzbzlib.c
|
||||
Folder=unalz
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit9]
|
||||
FileName=bzip2\bzlib_private.h
|
||||
Folder=bzip2
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit10]
|
||||
FileName=bzip2\compress.c
|
||||
Folder=bzip2
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit11]
|
||||
FileName=bzip2\crctable.c
|
||||
Folder=bzip2
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit12]
|
||||
FileName=bzip2\huffman.c
|
||||
Folder=bzip2
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit13]
|
||||
FileName=bzip2\randtable.c
|
||||
Folder=bzip2
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit14]
|
||||
FileName=zlib\adler32.c
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=$(CC) -c adler32.c -o adler32.o $(CFLAGS)
|
||||
|
||||
[Unit15]
|
||||
FileName=zlib\crc32.c
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=$(CC) -c crc32.c -o crc32.o $(CFLAGS)
|
||||
|
||||
[Unit16]
|
||||
FileName=zlib\crc32.h
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit17]
|
||||
FileName=zlib\infback.c
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=$(CC) -c infback.c -o infback.o $(CFLAGS)
|
||||
|
||||
[Unit18]
|
||||
FileName=zlib\inffast.c
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=$(CC) -c inffast.c -o inffast.o $(CFLAGS)
|
||||
|
||||
[Unit19]
|
||||
FileName=zlib\inffast.h
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit20]
|
||||
FileName=zlib\inffixed.h
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit21]
|
||||
FileName=zlib\inflate.c
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=$(CC) -c inflate.c -o inflate.o $(CFLAGS)
|
||||
|
||||
[Unit22]
|
||||
FileName=zlib\inflate.h
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit23]
|
||||
FileName=zlib\inftrees.c
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=$(CC) -c inftrees.c -o inftrees.o $(CFLAGS)
|
||||
|
||||
[Unit24]
|
||||
FileName=zlib\inftrees.h
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit25]
|
||||
FileName=zlib\zconf.h
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit26]
|
||||
FileName=zlib\zconf.in.h
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit27]
|
||||
FileName=zlib\zlib.h
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit28]
|
||||
FileName=zlib\zutil.c
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=$(CC) -c zutil.c -o zutil.o $(CFLAGS)
|
||||
|
||||
[Unit29]
|
||||
FileName=zlib\zutil.h
|
||||
Folder=zlib
|
||||
Compile=1
|
||||
CompileCpp=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit30]
|
||||
FileName=bzip2\huffman.c
|
||||
Folder=bzip2
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit31]
|
||||
FileName=bzip2\randtable.c
|
||||
Folder=bzip2
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit32]
|
||||
FileName=bzip2\randtable.c
|
||||
Folder=bzip2
|
||||
Compile=1
|
||||
CompileCpp=0
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[VersionInfo]
|
||||
Major=0
|
||||
Minor=1
|
||||
Release=1
|
||||
Build=1
|
||||
LanguageID=1033
|
||||
CharsetID=1252
|
||||
CompanyName=
|
||||
FileVersion=0.1
|
||||
FileDescription=Developed using the Dev-C++ IDE
|
||||
InternalName=
|
||||
LegalCopyright=
|
||||
LegalTrademarks=
|
||||
OriginalFilename=unalz.exe
|
||||
ProductName=unalz
|
||||
ProductVersion=0.1
|
||||
AutoIncBuildNr=0
|
||||
|
||||
[Unit7]
|
||||
FileName=bzip2\blocksort.c
|
||||
CompileCpp=0
|
||||
Folder=bzip2
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
||||
[Unit8]
|
||||
FileName=bzip2\bzlib.h
|
||||
CompileCpp=1
|
||||
Folder=bzip2
|
||||
Compile=1
|
||||
Link=1
|
||||
Priority=1000
|
||||
OverrideBuildCmd=0
|
||||
BuildCmd=
|
||||
|
|
@ -7,10 +7,6 @@ Project: "unalz"=.\unalz.dsp - Package Owner=<4>
|
|||
|
||||
Package=<5>
|
||||
{{{
|
||||
begin source code control
|
||||
"$/Home/unalz", VXBAAAAA
|
||||
.
|
||||
end source code control
|
||||
}}}
|
||||
|
||||
Package=<4>
|
||||
|
|
Loading…
Add table
Reference in a new issue