r= dougt@netscape.com
OS/2 bring up continues - Adding PR_CALLBACKs for VisualAge Compiler
This commit is contained in:
mkaply%us.ibm.com 2000-05-02 22:38:04 +00:00
parent 4234df5b70
commit 152f6f29e4
19 changed files with 154 additions and 71 deletions

View File

@ -124,18 +124,18 @@ nsString::nsString(const nsString& aString) {
* @update gess 1/4/99
* @param reference to a subsumeString
*/
#ifdef AIX
#if defined(AIX) || defined(XP_OS2_VACPP)
nsString::nsString(const nsSubsumeStr& aSubsumeStr) {
Initialize(*this,eTwoByte);
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX compiler
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX and VAC++ compilers
Subsume(*this,temp);
#else
nsString::nsString(nsSubsumeStr& aSubsumeStr) {
Initialize(*this,eTwoByte);
Subsume(*this,aSubsumeStr);
#endif /* AIX */
#endif /* AIX || XP_OS2_VACPP */
}
/**
@ -1081,14 +1081,14 @@ nsString& nsString::Assign(PRUnichar aChar) {
* @param
* @return
*/
#ifdef AIX
#if defined(AIX) || defined(XP_OS2_VACPP)
nsString& nsString::operator=(const nsSubsumeStr& aSubsumeString) {
nsSubsumeStr temp(aSubsumeString); // a temp is needed for the AIX compiler
nsSubsumeStr temp(aSubsumeString); // a temp is needed for the AIX and VAC++ compilers
Subsume(*this,temp);
#else
nsString& nsString::operator=(nsSubsumeStr& aSubsumeString) {
Subsume(*this,aSubsumeString);
#endif // AIX
#endif // AIX || XP_OS2_VACPP
return *this;
}
#endif
@ -2390,14 +2390,14 @@ nsAutoString::nsAutoString(PRUnichar aChar) : nsString(){
* @update gess 1/4/99
* @param reference to a subsumeString
*/
#ifdef AIX
#if defined(AIX) || defined(XP_OS2_VACPP)
nsAutoString::nsAutoString(const nsSubsumeStr& aSubsumeStr) :nsString() {
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX compiler
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX and VAC++ compilers
Subsume(*this,temp);
#else
nsAutoString::nsAutoString( nsSubsumeStr& aSubsumeStr) :nsString() {
Subsume(*this,aSubsumeStr);
#endif // AIX
#endif // AIX || XP_OS2_VACPP
}
/**

View File

@ -19,6 +19,17 @@
*
* Contributor(s):
* Pierre Phaneuf <pp@ludusdesign.com>
*
* This Original Code has been modified by IBM Corporation.
* Modifications made by IBM described herein are
* Copyright (c) International Business Machines
* Corporation, 2000
*
* Modifications to Mozilla code or documentation
* identified per MPL Section 3.3
*
* Date Modified by Description of modification
* 04/20/2000 IBM Corp. Added PR_CALLBACK for Optlink use in OS2
*/
#include <stdlib.h>
@ -138,10 +149,10 @@ nsCreateInstanceByProgID::operator()( const nsIID& aIID, void** aInstancePtr ) c
}
/* prototypes for the Mac */
PRBool
PRBool PR_CALLBACK
nsFactoryEntry_Destroy(nsHashKey *aKey, void *aData, void* closure);
PRBool
PRBool PR_CALLBACK
nsCID_Destroy(nsHashKey *aKey, void *aData, void* closure);
////////////////////////////////////////////////////////////////////////////////
// nsFactoryEntry
@ -1809,7 +1820,7 @@ struct CanUnload_closure {
nsIComponentLoader *native;
};
static PRBool
static PRBool PR_CALLBACK
CanUnload_enumerate(nsHashKey *key, void *aData, void *aClosure)
{
nsIComponentLoader *loader = (nsIComponentLoader *)aData;
@ -1893,7 +1904,7 @@ struct AutoReg_closure {
PRBool registered;
};
static PRBool
static PRBool PR_CALLBACK
AutoRegister_enumerate(nsHashKey *key, void *aData, void *aClosure)
{
nsIComponentLoader *loader = NS_STATIC_CAST(nsIComponentLoader *, aData);
@ -1910,7 +1921,7 @@ AutoRegister_enumerate(nsHashKey *key, void *aData, void *aClosure)
return NS_SUCCEEDED(closure->status) ? PR_TRUE : PR_FALSE;
}
static PRBool
static PRBool PR_CALLBACK
RegisterDeferred_enumerate(nsHashKey *key, void *aData, void *aClosure)
{
nsIComponentLoader *loader = NS_STATIC_CAST(nsIComponentLoader *, aData);
@ -2025,7 +2036,7 @@ nsComponentManagerImpl::AutoRegister(PRInt32 when, nsIFile *inDirSpec)
return closure.status;
}
static PRBool
static PRBool PR_CALLBACK
AutoRegisterComponent_enumerate(nsHashKey *key, void *aData, void *aClosure)
{
PRBool didRegister;

View File

@ -14,6 +14,18 @@
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1999 Netscape Communications Corporation. All Rights
* Reserved.
*
* Contributors:
* This Original Code has been modified by IBM Corporation.
* Modifications made by IBM described herein are
* Copyright (c) International Business Machines
* Corporation, 2000
*
* Modifications to Mozilla code or documentation
* identified per MPL Section 3.3
*
* Date Modified by Description of modification
* 04/20/2000 IBM Corp. Added PR_CALLBACK for Optlink use in OS2
*/
#include "prmem.h"
@ -51,7 +63,7 @@ nsNativeComponentLoader::nsNativeComponentLoader() :
NS_INIT_REFCNT();
}
static PRBool
static PRBool PR_CALLBACK
nsDll_Destroy(nsHashKey *aKey, void *aData, void* closure)
{
nsDll* entry = NS_STATIC_CAST(nsDll*, aData);
@ -289,7 +301,7 @@ nsNativeComponentLoader::RegisterComponentsInDir(PRInt32 when,
return rv;
}
static nsresult
static nsresult PR_CALLBACK
nsFreeLibrary(nsDll *dll, nsIServiceManager *serviceMgr, PRInt32 when)
{
nsresult rv = NS_ERROR_FAILURE;
@ -388,7 +400,7 @@ struct freeLibrariesClosure
PRInt32 when;
};
static PRBool
static PRBool PR_CALLBACK
nsFreeLibraryEnum(nsHashKey *aKey, void *aData, void* closure)
{
nsDll *dll = (nsDll *) aData;

View File

@ -18,6 +18,7 @@
* Rights Reserved.
*
* Contributor(s):
* IBM Corp.
*/
#include "nsIServiceManager.h"
@ -202,7 +203,7 @@ protected:
PRMonitor* mMonitor;
};
static PRBool
static PRBool PR_CALLBACK
DeleteEntry(nsHashKey *aKey, void *aData, void* closure)
{
nsServiceEntry* entry = (nsServiceEntry*)aData;

View File

@ -18,6 +18,7 @@
* Rights Reserved.
*
* Contributor(s):
* IBM Corp.
*/
#include "nsAtomTable.h"
@ -33,7 +34,7 @@ static nsrefcnt gAtoms;
static struct PLHashTable* gAtomHashTable;
#if defined(DEBUG) && (defined(XP_UNIX) || defined(XP_PC))
static PRIntn
static PRIntn PR_CALLBACK
DumpAtomLeaks(PLHashEntry *he, PRIntn index, void *arg)
{
AtomImpl* atom = (AtomImpl*) he->value;

View File

@ -18,6 +18,16 @@
* Rights Reserved.
*
* Contributor(s):
* This Original Code has been modified by IBM Corporation.
* Modifications made by IBM described herein are
* Copyright (c) International Business Machines
* Corporation, 2000
*
* Modifications to Mozilla code or documentation
* identified per MPL Section 3.3
*
* Date Modified by Description of modification
* 04/20/2000 IBM Corp. Added PR_CALLBACK for Optlink use in OS2
*/
#include "prmem.h"
@ -28,16 +38,16 @@
// Key operations
//
static PR_CALLBACK PLHashNumber _hashValue(const void *key)
static PLHashNumber PR_CALLBACK _hashValue(const void *key)
{
return ((const nsHashKey *) key)->HashValue();
}
static PR_CALLBACK PRIntn _hashKeyCompare(const void *key1, const void *key2) {
static PRIntn PR_CALLBACK _hashKeyCompare(const void *key1, const void *key2) {
return ((const nsHashKey *) key1)->Equals((const nsHashKey *) key2);
}
static PR_CALLBACK PRIntn _hashValueCompare(const void *value1,
static PRIntn PR_CALLBACK _hashValueCompare(const void *value1,
const void *value2) {
// We're not going to make any assumptions about value equality
return 0;
@ -47,19 +57,19 @@ static PR_CALLBACK PRIntn _hashValueCompare(const void *value1,
// Memory callbacks
//
static PR_CALLBACK void *_hashAllocTable(void *pool, PRSize size) {
static void * PR_CALLBACK _hashAllocTable(void *pool, PRSize size) {
return PR_MALLOC(size);
}
static PR_CALLBACK void _hashFreeTable(void *pool, void *item) {
static void PR_CALLBACK _hashFreeTable(void *pool, void *item) {
PR_DELETE(item);
}
static PR_CALLBACK PLHashEntry *_hashAllocEntry(void *pool, const void *key) {
static PLHashEntry * PR_CALLBACK _hashAllocEntry(void *pool, const void *key) {
return PR_NEW(PLHashEntry);
}
static PR_CALLBACK void _hashFreeEntry(void *pool, PLHashEntry *entry,
static void PR_CALLBACK _hashFreeEntry(void *pool, PLHashEntry *entry,
PRUintn flag) {
if (flag == HT_FREE_ENTRY) {
delete (nsHashKey *) (entry->key);
@ -81,7 +91,7 @@ struct _HashEnumerateArgs {
void* arg;
};
static PR_CALLBACK PRIntn _hashEnumerate(PLHashEntry *he, PRIntn i, void *arg)
static PRIntn PR_CALLBACK _hashEnumerate(PLHashEntry *he, PRIntn i, void *arg)
{
_HashEnumerateArgs* thunk = (_HashEnumerateArgs*)arg;
return thunk->fn((nsHashKey *) he->key, he->value, thunk->arg)
@ -194,7 +204,7 @@ void *nsHashtable::Remove(nsHashKey *aKey) {
// XXX This method was called _hashEnumerateCopy, but it didn't copy the element!
// I don't know how this was supposed to work since the elements are neither copied
// nor refcounted.
static PR_CALLBACK PRIntn _hashEnumerateShare(PLHashEntry *he, PRIntn i, void *arg)
static PRIntn PR_CALLBACK _hashEnumerateShare(PLHashEntry *he, PRIntn i, void *arg)
{
nsHashtable *newHashtable = (nsHashtable *)arg;
newHashtable->Put((nsHashKey *) he->key, he->value);
@ -218,7 +228,7 @@ void nsHashtable::Enumerate(nsHashtableEnumFunc aEnumFunc, void* closure) {
PL_HashTableEnumerateEntries(hashtable, _hashEnumerate, &thunk);
}
static PR_CALLBACK PRIntn _hashEnumerateRemove(PLHashEntry *he, PRIntn i, void *arg)
static PRIntn PR_CALLBACK _hashEnumerateRemove(PLHashEntry *he, PRIntn i, void *arg)
{
_HashEnumerateArgs* thunk = (_HashEnumerateArgs*)arg;
if (thunk)
@ -312,7 +322,7 @@ nsObjectHashtable::~nsObjectHashtable()
Reset();
}
PR_CALLBACK PRIntn
PRIntn PR_CALLBACK
nsObjectHashtable::CopyElement(PLHashEntry *he, PRIntn i, void *arg)
{
nsObjectHashtable *newHashtable = (nsObjectHashtable *)arg;
@ -361,7 +371,7 @@ nsObjectHashtable::RemoveAndDelete(nsHashKey *aKey)
////////////////////////////////////////////////////////////////////////////////
// nsSupportsHashtable: an nsHashtable where the elements are nsISupports*
static PR_CALLBACK PRBool
static PRBool PR_CALLBACK
_ReleaseElement(nsHashKey *aKey, void *aData, void* closure)
{
nsISupports* element = NS_STATIC_CAST(nsISupports*, aData);
@ -404,7 +414,7 @@ nsSupportsHashtable::Remove(nsHashKey *aKey)
return data;
}
static PR_CALLBACK PRIntn
static PRIntn PR_CALLBACK
_hashEnumerateCopy(PLHashEntry *he, PRIntn i, void *arg)
{
nsHashtable *newHashtable = (nsHashtable *)arg;

View File

@ -18,6 +18,16 @@
* Rights Reserved.
*
* Contributor(s):
* This Original Code has been modified by IBM Corporation.
* Modifications made by IBM described herein are
* Copyright (c) International Business Machines
* Corporation, 2000
*
* Modifications to Mozilla code or documentation
* identified per MPL Section 3.3
*
* Date Modified by Description of modification
* 04/20/2000 IBM Corp. Added PR_CALLBACK for Optlink use in OS2
*/
#ifndef nsHashtable_h__
@ -39,7 +49,7 @@ public:
// Enumerator callback function. Use
typedef PRBool (*nsHashtableEnumFunc)(nsHashKey *aKey, void *aData, void* closure);
typedef PRBool (* PR_CALLBACK nsHashtableEnumFunc)(nsHashKey *aKey, void *aData, void* closure);
class NS_COM nsHashtable {
protected:
@ -82,7 +92,7 @@ public:
PRBool RemoveAndDelete(nsHashKey *aKey);
protected:
static PR_CALLBACK PRIntn CopyElement(PLHashEntry *he, PRIntn i, void *arg);
static PRIntn PR_CALLBACK CopyElement(PLHashEntry *he, PRIntn i, void *arg);
nsHashtableCloneElementFunc mCloneElementFun;
void* mCloneElementClosure;

View File

@ -19,6 +19,7 @@
*
* Contributor(s):
* Pierre Phaneuf <pp@ludusdesign.com>
* IBM Corp.
*/
/*
@ -92,7 +93,7 @@ nsHashtableEnumerator::nsHashtableEnumerator (nsHashtable *aHash,
}
PRBool
PRBool PR_CALLBACK
hash_enumerator (nsHashKey *aKey, void *aObject, void *closure)
{
nsresult rv;

View File

@ -19,6 +19,7 @@
*
* Contributor(s):
* Pierre Phaneuf <pp@ludusdesign.com>
* IBM Corp.
*/
#define NS_IMPL_IDS
@ -91,7 +92,7 @@ nsresult nsObserverService::GetObserverService(nsIObserverService** anObserverSe
return NS_OK;
}
static PRBool
static PRBool PR_CALLBACK
ReleaseObserverList(nsHashKey *aKey, void *aData, void* closure)
{
nsIObserverList* observerList = NS_STATIC_CAST(nsIObserverList*, aData);

View File

@ -18,6 +18,7 @@
* Rights Reserved.
*
* Contributor(s):
* IBM Corp.
*/
#define NS_IMPL_IDS
@ -49,7 +50,7 @@ nsProperties::Create(nsISupports *outer, REFNSIID aIID, void **aResult)
return rv;
}
PRBool
PRBool PR_CALLBACK
nsProperties::ReleaseValues(nsHashKey* key, void* data, void* closure)
{
nsISupports* value = (nsISupports*)data;

View File

@ -18,6 +18,7 @@
* Rights Reserved.
*
* Contributor(s):
* IBM Corp.
*/
#ifndef nsProperties_h___
@ -41,7 +42,7 @@ public:
static NS_METHOD
Create(nsISupports *aOuter, REFNSIID aIID, void **aResult);
static PRBool ReleaseValues(nsHashKey* key, void* data, void* closure);
static PRBool PR_CALLBACK ReleaseValues(nsHashKey* key, void* data, void* closure);
};

View File

@ -18,6 +18,16 @@
* Rights Reserved.
*
* Contributor(s):
* This Original Code has been modified by IBM Corporation.
* Modifications made by IBM described herein are
* Copyright (c) International Business Machines
* Corporation, 2000
*
* Modifications to Mozilla code or documentation
* identified per MPL Section 3.3
*
* Date Modified by Description of modification
* 04/20/2000 IBM Corp. Added PR_CALLBACK for Optlink use in OS2
*/
#include "nsISizeOfHandler.h"
#include "nsIAtom.h"
@ -33,10 +43,10 @@ public:
// nsISizeOfHandler
NS_IMETHOD Init();
NS_IMETHOD RecordObject(void* aObject, PRBool* aResult);
NS_IMETHOD AddSize(nsIAtom* aKey, PRUint32 aSize);
NS_IMETHOD Report(nsISizeofReportFunc aFunc, void* aArg);
NS_IMETHOD GetTotals(PRUint32* aCountResult, PRUint32* aTotalSizeResult);
NS_IMETHOD PR_CALLBACK RecordObject(void* aObject, PRBool* aResult);
NS_IMETHOD PR_CALLBACK AddSize(nsIAtom* aKey, PRUint32 aSize);
NS_IMETHOD PR_CALLBACK Report(nsISizeofReportFunc aFunc, void* aArg);
NS_IMETHOD PR_CALLBACK GetTotals(PRUint32* aCountResult, PRUint32* aTotalSizeResult);
protected:
PRUint32 mTotalSize;

View File

@ -124,18 +124,18 @@ nsString::nsString(const nsString& aString) {
* @update gess 1/4/99
* @param reference to a subsumeString
*/
#ifdef AIX
#if defined(AIX) || defined(XP_OS2_VACPP)
nsString::nsString(const nsSubsumeStr& aSubsumeStr) {
Initialize(*this,eTwoByte);
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX compiler
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX and VAC++ compilers
Subsume(*this,temp);
#else
nsString::nsString(nsSubsumeStr& aSubsumeStr) {
Initialize(*this,eTwoByte);
Subsume(*this,aSubsumeStr);
#endif /* AIX */
#endif /* AIX || XP_OS2_VACPP */
}
/**
@ -1081,14 +1081,14 @@ nsString& nsString::Assign(PRUnichar aChar) {
* @param
* @return
*/
#ifdef AIX
#if defined(AIX) || defined(XP_OS2_VACPP)
nsString& nsString::operator=(const nsSubsumeStr& aSubsumeString) {
nsSubsumeStr temp(aSubsumeString); // a temp is needed for the AIX compiler
nsSubsumeStr temp(aSubsumeString); // a temp is needed for the AIX and VAC++ compilers
Subsume(*this,temp);
#else
nsString& nsString::operator=(nsSubsumeStr& aSubsumeString) {
Subsume(*this,aSubsumeString);
#endif // AIX
#endif // AIX || XP_OS2_VACPP
return *this;
}
#endif
@ -2390,14 +2390,14 @@ nsAutoString::nsAutoString(PRUnichar aChar) : nsString(){
* @update gess 1/4/99
* @param reference to a subsumeString
*/
#ifdef AIX
#if defined(AIX) || defined(XP_OS2_VACPP)
nsAutoString::nsAutoString(const nsSubsumeStr& aSubsumeStr) :nsString() {
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX compiler
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX and VAC++ compilers
Subsume(*this,temp);
#else
nsAutoString::nsAutoString( nsSubsumeStr& aSubsumeStr) :nsString() {
Subsume(*this,aSubsumeStr);
#endif // AIX
#endif // AIX || XP_OS2_VACPP
}
/**

View File

@ -18,6 +18,7 @@
* Rights Reserved.
*
* Contributor(s):
* IBM Corp.
*/
#ifndef nsVoidArray_h___
#define nsVoidArray_h___
@ -26,7 +27,7 @@
class nsISizeOfHandler;
// Enumerator callback function. Return PR_FALSE to stop
typedef PRBool (*nsVoidArrayEnumFunc)(void* aElement, void *aData);
typedef PRBool (* PR_CALLBACK nsVoidArrayEnumFunc)(void* aElement, void *aData);
/// A basic zero-based array of void*'s that manages its own memory
class NS_COM nsVoidArray {

View File

@ -18,6 +18,7 @@
* Rights Reserved.
*
* Contributor(s):
* IBM Corp.
*/
#define NS_IMPL_IDS
@ -30,7 +31,7 @@
#include "nsString.h"
#include "nsCRT.h"
#include <fcntl.h>
#ifdef NS_WIN32
#if defined(NS_WIN32) || defined(XP_OS2_VACPP)
#include <io.h>
#else
#include <unistd.h>

View File

@ -19,6 +19,17 @@
*
* Contributor(s):
* Pierre Phaneuf <pp@ludusdesign.com>
*
* This Original Code has been modified by IBM Corporation.
* Modifications made by IBM described herein are
* Copyright (c) International Business Machines
* Corporation, 2000
*
* Modifications to Mozilla code or documentation
* identified per MPL Section 3.3
*
* Date Modified by Description of modification
* 04/20/2000 IBM Corp. Added PR_CALLBACK for Optlink use in OS2
*/
@ -42,10 +53,10 @@
static NS_DEFINE_CID(kEventQueueServiceCID, NS_EVENTQUEUESERVICE_CID);
static void* EventHandler(PLEvent *self);
static void DestroyHandler(PLEvent *self);
static void* CompletedEventHandler(PLEvent *self);
static void CompletedDestroyHandler(PLEvent *self) ;
static void* PR_CALLBACK EventHandler(PLEvent *self);
static void PR_CALLBACK DestroyHandler(PLEvent *self);
static void* PR_CALLBACK CompletedEventHandler(PLEvent *self);
static void PR_CALLBACK CompletedDestroyHandler(PLEvent *self) ;
nsProxyObjectCallInfo::nsProxyObjectCallInfo( nsProxyObject* owner,
nsXPTMethodInfo *methodInfo,

View File

@ -124,18 +124,18 @@ nsString::nsString(const nsString& aString) {
* @update gess 1/4/99
* @param reference to a subsumeString
*/
#ifdef AIX
#if defined(AIX) || defined(XP_OS2_VACPP)
nsString::nsString(const nsSubsumeStr& aSubsumeStr) {
Initialize(*this,eTwoByte);
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX compiler
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX and VAC++ compilers
Subsume(*this,temp);
#else
nsString::nsString(nsSubsumeStr& aSubsumeStr) {
Initialize(*this,eTwoByte);
Subsume(*this,aSubsumeStr);
#endif /* AIX */
#endif /* AIX || XP_OS2_VACPP */
}
/**
@ -1081,14 +1081,14 @@ nsString& nsString::Assign(PRUnichar aChar) {
* @param
* @return
*/
#ifdef AIX
#if defined(AIX) || defined(XP_OS2_VACPP)
nsString& nsString::operator=(const nsSubsumeStr& aSubsumeString) {
nsSubsumeStr temp(aSubsumeString); // a temp is needed for the AIX compiler
nsSubsumeStr temp(aSubsumeString); // a temp is needed for the AIX and VAC++ compilers
Subsume(*this,temp);
#else
nsString& nsString::operator=(nsSubsumeStr& aSubsumeString) {
Subsume(*this,aSubsumeString);
#endif // AIX
#endif // AIX || XP_OS2_VACPP
return *this;
}
#endif
@ -2390,14 +2390,14 @@ nsAutoString::nsAutoString(PRUnichar aChar) : nsString(){
* @update gess 1/4/99
* @param reference to a subsumeString
*/
#ifdef AIX
#if defined(AIX) || defined(XP_OS2_VACPP)
nsAutoString::nsAutoString(const nsSubsumeStr& aSubsumeStr) :nsString() {
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX compiler
nsSubsumeStr temp(aSubsumeStr); // a temp is needed for the AIX and VAC++ compilers
Subsume(*this,temp);
#else
nsAutoString::nsAutoString( nsSubsumeStr& aSubsumeStr) :nsString() {
Subsume(*this,aSubsumeStr);
#endif // AIX
#endif // AIX || XP_OS2_VACPP
}
/**

View File

@ -18,6 +18,7 @@
* Rights Reserved.
*
* Contributor(s):
* IBM Corp.
*/
/*
@ -32,7 +33,7 @@
PRLock* gLock;
int gCount;
static void run(void* arg)
static void PR_CALLBACK run(void* arg)
{
for (int i = 0; i < 1000000; ++i) {
nsAutoLock guard(gLock);

View File

@ -18,6 +18,16 @@
* Rights Reserved.
*
* Contributor(s):
* This Original Code has been modified by IBM Corporation.
* Modifications made by IBM described herein are
* Copyright (c) International Business Machines
* Corporation, 2000
*
* Modifications to Mozilla code or documentation
* identified per MPL Section 3.3
*
* Date Modified by Description of modification
* 04/20/2000 IBM Corp. Added PR_CALLBACK for Optlink use in OS2
*/
#ifndef nsThread_h__
@ -45,9 +55,9 @@ public:
nsresult RegisterThreadSelf();
void SetPRThread(PRThread* thread) { mThread = thread; }
static void Main(void* arg);
static void Exit(void* arg);
static void Shutdown();
static void PR_CALLBACK Main(void* arg);
static void PR_CALLBACK Exit(void* arg);
static void PR_CALLBACK Shutdown();
static PRUintn kIThreadSelfIndex;