Use NS_PTR_TO_INT32 macros to do 64-bit safe pointer conversions.
Bug #20860 r=Roland.Mainz@informatik.med.uni-giessen.de sr=brendan@mozilla.org git-svn-id: svn://10.0.0.236/trunk@100998 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -24,6 +24,7 @@
|
||||
#include "prprf.h"
|
||||
#include "prmem.h"
|
||||
|
||||
#include "nscore.h"
|
||||
#include "nsProxyEvent.h"
|
||||
#include "nsIProxyObjectManager.h"
|
||||
#include "nsProxyEventPrivate.h"
|
||||
@@ -48,8 +49,8 @@ public:
|
||||
}
|
||||
|
||||
PRUint32 HashCode(void) const {
|
||||
// XXX what about 64-bit machines?
|
||||
return (PRUint32)mRootObjectKey ^ (PRUint32)mDestQueueKey ^ mProxyType;
|
||||
return NS_PTR_TO_INT32(mRootObjectKey) ^
|
||||
NS_PTR_TO_INT32(mDestQueueKey) ^ mProxyType;
|
||||
}
|
||||
|
||||
PRBool Equals(const nsHashKey *aKey) const {
|
||||
|
||||
@@ -307,7 +307,7 @@ void TestCase_NestedLoop(void *arg)
|
||||
rv = eventQService->GetThreadEventQueue(NS_CURRENT_THREAD, &eventQ);
|
||||
|
||||
printf("Thread (%d) Prior to calling proxyObject->Test.\n", threadNumber);
|
||||
rv = proxyObject->Test((PRInt32)eventQ, 0, &retval);
|
||||
rv = proxyObject->Test(NS_PTR_TO_INT32(eventQ), 0, &retval);
|
||||
printf("Thread (%d) proxyObject error: %d.\n", threadNumber, rv);
|
||||
|
||||
printf("Deleting Proxy Object (%d)\n", threadNumber );
|
||||
|
||||
Reference in New Issue
Block a user