зеркало из https://github.com/mozilla/pjs.git
Declaring callback functions appropriately.
Fixing OS/2 tinderbox bustage
This commit is contained in:
Родитель
fa3b3f6439
Коммит
f05b4490d6
|
@ -508,7 +508,8 @@ void nsZlibAllocator::zFree(void *ptr)
|
|||
return;
|
||||
}
|
||||
|
||||
static void *zlibAlloc(void *opaque, uInt items, uInt size)
|
||||
PR_STATIC_CALLBACK(void *)
|
||||
zlibAlloc(void *opaque, uInt items, uInt size)
|
||||
{
|
||||
nsZlibAllocator *zallocator = (nsZlibAllocator *)opaque;
|
||||
if (zallocator)
|
||||
|
@ -517,7 +518,8 @@ static void *zlibAlloc(void *opaque, uInt items, uInt size)
|
|||
return calloc(items, size);
|
||||
}
|
||||
|
||||
static void zlibFree(void *opaque, void *ptr)
|
||||
PR_STATIC_CALLBACK(void)
|
||||
zlibFree(void *opaque, void *ptr)
|
||||
{
|
||||
nsZlibAllocator *zallocator = (nsZlibAllocator *)opaque;
|
||||
if (zallocator)
|
||||
|
|
|
@ -67,6 +67,15 @@
|
|||
#define PR_PUBLIC_API(__type) __type
|
||||
#endif
|
||||
|
||||
#ifdef XP_OS2_VACPP
|
||||
#define PR_CALLBACK _Optlink
|
||||
#define PR_STATIC_CALLBACK(__x) static __x PR_CALLBACK
|
||||
#else
|
||||
#define PR_CALLBACK
|
||||
#define PR_STATIC_CALLBACK(__x) static __x
|
||||
#endif
|
||||
|
||||
|
||||
#define NS_STATIC_CAST(__type, __ptr) ((__type)(__ptr))
|
||||
|
||||
#define PRFileDesc FILE
|
||||
|
|
Загрузка…
Ссылка в новой задаче