44#define HFILE_ERROR ((HFILE)-1)
48#define _lwrite(a, b, c) (long)(_hwrite(a, b, (long)c))
67#include "wine/unicode.h"
80#define LZ_HEADER_LEN 14
91#define LZ_TABLE_SIZE 0x1000
115#define MAX_LZSTATES 16
118#define LZ_MIN_HANDLE 0x400
119#define IS_LZ_HANDLE(h) (((h) >= LZ_MIN_HANDLE) && ((h) < LZ_MIN_HANDLE+MAX_LZSTATES))
120#define GET_LZ_STATE(h) (IS_LZ_HANDLE(h) ? lzstates[(h)-LZ_MIN_HANDLE] : NULL)
123#define GET(lzs,b) _lzget(lzs,&b)
124#define GET_FLUSH(lzs) lzs->getcur=lzs->getlen;
170 if (
head->compressiontype!=
'A')
204 TRACE(
"(%d)\n",hfSrc);
287 WARN(
"Specified a directory or what? (%s)\n",
in);
359#define DECOMPRESS_ONE_BYTE \
360 if (lzs->stringlen) { \
361 b = lzs->table[lzs->stringpos]; \
362 lzs->stringpos = (lzs->stringpos+1)&0xFFF; \
365 if (!(lzs->bytetype&0x100)) { \
367 return toread-howmuch; \
368 lzs->bytetype = b|0xFF00; \
370 if (lzs->bytetype & 1) { \
372 return toread-howmuch; \
376 if (1!=GET(lzs,b1)) \
377 return toread-howmuch; \
378 if (1!=GET(lzs,b2)) \
379 return toread-howmuch; \
386 lzs->stringpos = b1|((b2&0xf0)<<4); \
387 lzs->stringlen = (b2&0xf)+2; \
389 b = lzs->table[lzs->stringpos];\
390 lzs->stringpos = (lzs->stringpos+1)&0xFFF;\
395 lzs->table[lzs->curtabent++]= b; \
396 lzs->curtabent &= 0xFFF; \
429#undef DECOMPRESS_ONE_BYTE
474 int usedlzinit = 0,
ret, wret;
491 if ((
INT)
src <= 0)
return 0;
492 if (
src != oldsrc) usedlzinit=1;
539 if (!(
p =
strrchr( mfn,
'\\' )))
p = mfn;
577 if ((
INT)cfd <= 0)
return fd;
636 IN DWORD dwCreationDisposition,
639 WARN(
" LZCreateFileW Not implemented!\n");
char * strcat(char *DstString, const char *SrcString)
int memcmp(void *Buffer1, void *Buffer2, ACPI_SIZE Count)
ACPI_SIZE strlen(const char *String)
char * strcpy(char *DstString, const char *SrcString)
char * strchr(const char *String, int ch)
char * strpbrk(const char *String, const char *Delimiters)
struct outqueuenode * head
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
#define DEBUG_CHANNEL(args)
#define ERROR_CALL_NOT_IMPLEMENTED
#define HeapFree(x, y, z)
#define WideCharToMultiByte
#define MultiByteToWideChar
HFILE WINAPI OpenFile(LPCSTR lpFileName, LPOFSTRUCT lpReOpenBuff, UINT uStyle)
BOOL WINAPI SetFileTime(IN HANDLE hFile, CONST FILETIME *lpCreationTime OPTIONAL, CONST FILETIME *lpLastAccessTime OPTIONAL, CONST FILETIME *lpLastWriteTime OPTIONAL)
BOOL WINAPI GetFileTime(IN HANDLE hFile, OUT LPFILETIME lpCreationTime OPTIONAL, OUT LPFILETIME lpLastAccessTime OPTIONAL, OUT LPFILETIME lpLastWriteTime OPTIONAL)
_Must_inspect_result_ _In_opt_ PFLT_INSTANCE _Out_ PHANDLE FileHandle
GLuint GLuint GLsizei GLenum type
GLboolean GLboolean GLboolean b
GLenum GLuint GLenum GLsizei const GLchar * buf
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
int WINAPI _lclose(HFILE hFile)
LONG WINAPI _llseek(HFILE hFile, LONG lOffset, int iOrigin)
long WINAPI _hread(HFILE hFile, LPVOID lpBuffer, long lBytes)
static LPSTR LZEXPAND_MangleName(LPCSTR fn)
static int _lzget(struct lzstate *lzs, BYTE *b)
#define DECOMPRESS_ONE_BYTE
LONG WINAPI LZSeek(HFILE fd, LONG off, INT type)
INT WINAPI LZRead(HFILE fd, LPSTR vbuf, INT toread)
HFILE WINAPI LZOpenFileW(LPWSTR fn, LPOFSTRUCT ofs, WORD mode)
static const BYTE LZMagic[LZ_MAGIC_LEN]
LONG WINAPI LZCopy(HFILE src, HFILE dest)
static struct lzstate * lzstates[MAX_LZSTATES]
INT WINAPI GetExpandedNameW(LPWSTR in, LPWSTR out)
void WINAPI LZClose(HFILE fd)
static INT read_header(HFILE fd, struct lzfileheader *head)
HFILE WINAPI LZInit(HFILE hfSrc)
HFILE WINAPI LZOpenFileA(LPSTR fn, LPOFSTRUCT ofs, WORD mode)
INT WINAPI GetExpandedNameA(LPSTR in, LPSTR out)
#define LZERROR_GLOBALLOC
#define LZERROR_UNKNOWNALG
#define LZERROR_BADINHANDLE
#define memcpy(s1, s2, n)
_CRT_RESTORE_GCC_WARNINGS _CRT_DISABLE_GCC_WARNINGS _Check_return_ _CRTIMP _CONST_RETURN char *__cdecl strrchr(_In_z_ const char *_Str, _In_ int _Ch)
BYTE table[LZ_TABLE_SIZE]
static GLenum _GLUfuncptr fn
UINT WINAPI _lwrite(_In_ HFILE hFile, _In_reads_bytes_(uBytes) LPCCH lpBuffer, _In_ UINT uBytes)