mirror of
https://github.com/aaru-dps/fstester.git
synced 2025-12-16 19:24:39 +00:00
Some Mac OS refactor.
This commit is contained in:
@@ -55,20 +55,20 @@ enum
|
|||||||
#if __MWERKS__ <= 0x2100
|
#if __MWERKS__ <= 0x2100
|
||||||
|
|
||||||
// There's no MacTypes.h in old CodeWarrior
|
// There's no MacTypes.h in old CodeWarrior
|
||||||
typedef signed char int8_t;
|
typedef signed char int8_t;
|
||||||
typedef unsigned char uint8_t;
|
typedef unsigned char uint8_t;
|
||||||
typedef short int16_t;
|
typedef short int16_t;
|
||||||
typedef unsigned short uint16_t;
|
typedef unsigned short uint16_t;
|
||||||
typedef long int32_t;
|
typedef long int32_t;
|
||||||
typedef unsigned long uint32_t;
|
typedef unsigned long uint32_t;
|
||||||
typedef long long int64_t;
|
typedef long long int64_t;
|
||||||
typedef unsigned long long uint64_t;
|
typedef unsigned long long uint64_t;
|
||||||
|
|
||||||
#define kHasNoINITs (0x0080) /* Files only (Extensions/Control Panels only) */
|
#define kHasNoINITs (0x0080) /* Files only (Extensions/Control Panels only) */
|
||||||
|
|
||||||
#if __MWERKS__ <= 0x1800
|
#if __MWERKS__ <= 0x1800
|
||||||
// Old CodeWarrior C library does not include snprintf()
|
// Old CodeWarrior C library does not include snprintf()
|
||||||
int snprintf(char *str, size_t size, const char *format, ...);
|
int snprintf(char* str, size_t size, const char* format, ...);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
enum
|
enum
|
||||||
|
|||||||
@@ -137,7 +137,7 @@ enum
|
|||||||
/*MemoryDispatch errors*/
|
/*MemoryDispatch errors*/
|
||||||
enum
|
enum
|
||||||
{
|
{
|
||||||
notEnoughMemoryErr = -620, /*insufficient physical memory*/
|
notEnoughMemoryErr = -620 /*insufficient physical memory*/
|
||||||
};
|
};
|
||||||
|
|
||||||
enum
|
enum
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ static OSErr SaveResourceToNewFile(int16_t vRefNum,
|
|||||||
|
|
||||||
h = NewHandle(length);
|
h = NewHandle(length);
|
||||||
|
|
||||||
if(!h) return notEnoughMemoryErr;
|
if(!h) return -620; // notEnoughMemoryErr
|
||||||
|
|
||||||
memcpy(*h, buffer, length);
|
memcpy(*h, buffer, length);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user