mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-31 16:50:58 +00:00
Tweak
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@16474 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
ea2fc4b9dc
commit
e9733d43d2
2 changed files with 10 additions and 4 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
2003-04-15 Richard Frith-Macdonald <rfm@gnu.org>
|
||||||
|
|
||||||
|
* Source/NSData.m: Experimantal disable ReadFile and WriteFile on MINGW
|
||||||
|
|
||||||
2003-04-14 Richard Frith-Macdonald <rfm@gnu.org>
|
2003-04-14 Richard Frith-Macdonald <rfm@gnu.org>
|
||||||
|
|
||||||
* Source/NSObjCRuntime.m: NSClassFromString(), NSSelectorFromString()
|
* Source/NSObjCRuntime.m: NSClassFromString(), NSSelectorFromString()
|
||||||
|
|
|
@ -84,6 +84,8 @@
|
||||||
#include <unistd.h> /* SEEK_* on SunOS 4 */
|
#include <unistd.h> /* SEEK_* on SunOS 4 */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#define USE_WINDOWS_IO 0
|
||||||
|
|
||||||
#ifdef HAVE_MMAP
|
#ifdef HAVE_MMAP
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <sys/mman.h>
|
#include <sys/mman.h>
|
||||||
|
@ -132,7 +134,7 @@ readContentsOfFile(NSString* path, void** buf, unsigned int* len, NSZone* zone)
|
||||||
FILE *theFile = 0;
|
FILE *theFile = 0;
|
||||||
void *tmp = 0;
|
void *tmp = 0;
|
||||||
int c;
|
int c;
|
||||||
#if defined(__MINGW__)
|
#if USE_WINDOWS_IO && defined(__MINGW__)
|
||||||
HANDLE fh;
|
HANDLE fh;
|
||||||
DWORD fileLength;
|
DWORD fileLength;
|
||||||
DWORD high;
|
DWORD high;
|
||||||
|
@ -152,7 +154,7 @@ readContentsOfFile(NSString* path, void** buf, unsigned int* len, NSZone* zone)
|
||||||
return NO;
|
return NO;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(__MINGW__)
|
#if USE_WINDOWS_IO && defined(__MINGW__)
|
||||||
fh = CreateFile(thePath, GENERIC_READ, FILE_SHARE_READ, 0, OPEN_EXISTING,
|
fh = CreateFile(thePath, GENERIC_READ, FILE_SHARE_READ, 0, OPEN_EXISTING,
|
||||||
FILE_ATTRIBUTE_NORMAL, 0);
|
FILE_ATTRIBUTE_NORMAL, 0);
|
||||||
if (fh == INVALID_HANDLE_VALUE)
|
if (fh == INVALID_HANDLE_VALUE)
|
||||||
|
@ -847,7 +849,7 @@ static unsigned gsu32Align;
|
||||||
char thePath[BUFSIZ*2+8];
|
char thePath[BUFSIZ*2+8];
|
||||||
char theRealPath[BUFSIZ*2];
|
char theRealPath[BUFSIZ*2];
|
||||||
int c;
|
int c;
|
||||||
#if defined(__MINGW__)
|
#if USE_WINDOWS_IO && defined(__MINGW__)
|
||||||
NSString *tmppath = path;
|
NSString *tmppath = path;
|
||||||
HANDLE fh;
|
HANDLE fh;
|
||||||
DWORD wroteBytes;
|
DWORD wroteBytes;
|
||||||
|
@ -863,7 +865,7 @@ static unsigned gsu32Align;
|
||||||
return NO;
|
return NO;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(__MINGW__)
|
#if USE_WINDOWS_IO && defined(__MINGW__)
|
||||||
if (useAuxiliaryFile)
|
if (useAuxiliaryFile)
|
||||||
{
|
{
|
||||||
tmppath = [path stringByAppendingPathExtension: @"tmp"];
|
tmppath = [path stringByAppendingPathExtension: @"tmp"];
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue