mirror of
https://github.com/reactos/reactos.git
synced 2024-12-27 17:44:45 +00:00
Sync to Wine-20040309
svn path=/trunk/; revision=8647
This commit is contained in:
parent
63c72aa8a8
commit
dbdb5a1f76
3 changed files with 10 additions and 18 deletions
|
@ -42,14 +42,6 @@
|
|||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(cabinet);
|
||||
|
||||
/* ReactOS Hack */
|
||||
extern inline DWORD WINAPI GetLastError(void)
|
||||
{
|
||||
DWORD ret;
|
||||
__asm__ __volatile__( ".byte 0x64\n\tmovl 0x34,%0" : "=r" (ret) );
|
||||
return ret;
|
||||
}
|
||||
|
||||
THOSE_ZIP_CONSTS;
|
||||
|
||||
/* all the file IO is abstracted into these routines:
|
||||
|
@ -74,7 +66,7 @@ BOOL cabinet_open(struct cabinet *cab)
|
|||
/* seek to end of file and get the length */
|
||||
if ((cab->filelen = SetFilePointer(fh, 0, NULL, FILE_END)) == INVALID_SET_FILE_POINTER) {
|
||||
if (GetLastError() != NO_ERROR) {
|
||||
ERR("Seek END failed: %s", debugstr_a(name));
|
||||
ERR("Seek END failed: %s\n", debugstr_a(name));
|
||||
CloseHandle(fh);
|
||||
return FALSE;
|
||||
}
|
||||
|
@ -82,7 +74,7 @@ BOOL cabinet_open(struct cabinet *cab)
|
|||
|
||||
/* return to the start of the file */
|
||||
if (SetFilePointer(fh, 0, NULL, FILE_BEGIN) == INVALID_SET_FILE_POINTER) {
|
||||
ERR("Seek BEGIN failed: %s", debugstr_a(name));
|
||||
ERR("Seek BEGIN failed: %s\n", debugstr_a(name));
|
||||
CloseHandle(fh);
|
||||
return FALSE;
|
||||
}
|
||||
|
@ -228,7 +220,7 @@ BOOL file_open(struct cab_file *fi, BOOL lower, LPCSTR dir)
|
|||
fi->fh = 0;
|
||||
}
|
||||
} else
|
||||
ERR("Couldn't ensure filepath for %s", debugstr_a(name));
|
||||
ERR("Couldn't ensure filepath for %s\n", debugstr_a(name));
|
||||
|
||||
if (!ok) {
|
||||
ERR("Couldn't open file %s for writing\n", debugstr_a(name));
|
||||
|
@ -287,7 +279,7 @@ void cabinet_skip(struct cabinet *cab, cab_off_t distance)
|
|||
TRACE("(cab == ^%p, distance == %u)\n", cab, distance);
|
||||
if (SetFilePointer(cab->fh, distance, NULL, FILE_CURRENT) == INVALID_SET_FILE_POINTER) {
|
||||
if (distance != INVALID_SET_FILE_POINTER)
|
||||
ERR("%s", debugstr_a((char *) cab->filename));
|
||||
ERR("%s\n", debugstr_a((char *) cab->filename));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2099,7 +2091,7 @@ void find_cabinet_file(char **cabname, LPCSTR origcab) {
|
|||
}
|
||||
|
||||
do {
|
||||
TRACE("trying cab == %s", debugstr_a(cab));
|
||||
TRACE("trying cab == %s\n", debugstr_a(cab));
|
||||
|
||||
/* we don't want null cabinet filenames */
|
||||
if (name[0] == '\0') {
|
||||
|
|
|
@ -36,12 +36,12 @@
|
|||
|
||||
#define CAB_SEARCH_SIZE (32*1024)
|
||||
|
||||
typedef unsigned char cab_UBYTE; /* 8 bits */
|
||||
typedef unsigned short cab_UWORD; /* 16 bits */
|
||||
typedef unsigned int cab_ULONG; /* 32 bits */
|
||||
typedef signed int cab_LONG; /* 32 bits */
|
||||
typedef unsigned char cab_UBYTE; /* 8 bits */
|
||||
typedef UINT16 cab_UWORD; /* 16 bits */
|
||||
typedef UINT32 cab_ULONG; /* 32 bits */
|
||||
typedef INT32 cab_LONG; /* 32 bits */
|
||||
|
||||
typedef unsigned int cab_off_t;
|
||||
typedef UINT32 cab_off_t;
|
||||
|
||||
/* number of bits in a ULONG */
|
||||
#ifndef CHAR_BIT
|
||||
|
|
0
reactos/lib/cabinet/winehq2ros.patch
Normal file
0
reactos/lib/cabinet/winehq2ros.patch
Normal file
Loading…
Reference in a new issue