Differences From Artifact [9880062333]:
- File
src/OFFile.m
— part of check-in
[b31bd48f90]
at
2018-05-26 14:49:26
on branch trunk
— Remove #define INTUITION_CLASSES_H hack
This has been fixed upstream in amiga-gcc. (user: js, size: 11427) [annotate] [blame] [check-ins using]
To Artifact [0bea227955]:
- File src/OFFile.m — part of check-in [aa0384d1bf] at 2018-07-28 18:45:36 on branch trunk — Rename OFLocalization -> OFLocale (user: js, size: 11403) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
26 27 28 29 30 31 32 | #include "unistd_wrapper.h" #ifdef HAVE_SYS_STAT_H # include <sys/stat.h> #endif #import "OFFile.h" | | | 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | #include "unistd_wrapper.h" #ifdef HAVE_SYS_STAT_H # include <sys/stat.h> #endif #import "OFFile.h" #import "OFLocale.h" #import "OFString.h" #import "OFURL.h" #import "OFInitializationFailedException.h" #import "OFInvalidArgumentException.h" #import "OFNotOpenException.h" #import "OFOpenItemFailedException.h" |
︙ | ︙ | |||
220 221 222 223 224 225 226 | flags |= O_BINARY | O_CLOEXEC; # if defined(OF_WINDOWS) if ((handle = _wopen([path UTF16String], flags, _S_IREAD | _S_IWRITE)) == -1) # elif defined(OF_HAVE_OFF64_T) if ((handle = open64([path cStringWithEncoding: | | | | | 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 | flags |= O_BINARY | O_CLOEXEC; # if defined(OF_WINDOWS) if ((handle = _wopen([path UTF16String], flags, _S_IREAD | _S_IWRITE)) == -1) # elif defined(OF_HAVE_OFF64_T) if ((handle = open64([path cStringWithEncoding: [OFLocale encoding]], flags, 0666)) == -1) # else if ((handle = open([path cStringWithEncoding: [OFLocale encoding]], flags, 0666)) == -1) # endif @throw [OFOpenItemFailedException exceptionWithPath: path mode: mode errNo: errno]; #else if ((handle = malloc(sizeof(*handle))) == NULL) @throw [OFOutOfMemoryException exceptionWithRequestedSize: sizeof(*handle)]; @try { if ((flags = parseMode([mode UTF8String], &handle->append)) == -1) @throw [OFInvalidArgumentException exception]; if ((handle->handle = Open([path cStringWithEncoding: [OFLocale encoding]], flags)) == 0) { int errNo; switch (IoErr()) { case ERROR_OBJECT_IN_USE: case ERROR_DISK_NOT_VALIDATED: errNo = EBUSY; break; |
︙ | ︙ |