Changeset 21113 in vbox
- Timestamp:
- Jul 1, 2009 11:48:47 AM (16 years ago)
- Location:
- trunk/src/libs/xpcom18a4
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/libs/xpcom18a4/ipc/ipcd/extensions/dconnect/src/ipcDConnectService.cpp
r17381 r21113 1533 1533 if (NS_SUCCEEDED(rv) && (stub->PeerID() == peer)) 1534 1534 { 1535 void *p = stub->Instance();1535 DConAddr p = stub->Instance(); 1536 1536 writer.PutBytes(&p, sizeof(p)); 1537 1537 } … … 1850 1850 { 1851 1851 // send the wrapper instance back to the peer 1852 void *p = stub->Stub()->Instance();1852 DConAddr p = stub->Stub()->Instance(); 1853 1853 writer.PutBytes(&p, sizeof(p)); 1854 1854 } … … 3473 3473 { 3474 3474 const DConnectSetupQueryInterface *setupQI = (const DConnectSetupQueryInterface *) setup; 3475 DConnectInstance *instance = (DConnectInstance *)setupQI->instance; 3475 3476 3476 3477 // make sure we've been sent a valid wrapper 3477 if (!CheckInstanceAndAddRef( setupQI->instance, peer))3478 if (!CheckInstanceAndAddRef(instance, peer)) 3478 3479 { 3479 3480 NS_NOTREACHED("instance wrapper not found"); … … 3482 3483 else 3483 3484 { 3484 rv = setupQI->instance->RealInstance()->QueryInterface(setupQI->iid, (void **) &instance);3485 setupQI->instance->Release();3485 rv = instance->RealInstance()->QueryInterface(setupQI->iid, (void **) &instance); 3486 instance->Release(); 3486 3487 } 3487 3488 break; … … 3588 3589 msg.flags = 0; 3589 3590 msg.request_index = setup->request_index; 3590 msg.instance = wrapper;3591 msg.instance = (DConAddr)wrapper; 3591 3592 msg.status = rv; 3592 3593 … … 3623 3624 peer, release->instance)); 3624 3625 3625 DConnectInstance *wrapper = release->instance;3626 DConnectInstance *wrapper = (DConnectInstance *)release->instance; 3626 3627 3627 3628 nsAutoLock lock (mLock); … … 3658 3659 peer, invoke->instance, invoke->method_index)); 3659 3660 3660 DConnectInstance *wrapper = invoke->instance;3661 DConnectInstance *wrapper = (DConnectInstance *)invoke->instance; 3661 3662 3662 3663 ipcMessageReader reader((const PRUint8 *) (invoke + 1), opLen - sizeof(*invoke)); -
trunk/src/libs/xpcom18a4/ipc/ipcd/extensions/dconnect/src/ipcDConnectService.h
r7154 r21113 144 144 }; 145 145 146 typedef class DConnectInstance*DConAddr;146 typedef PRUint64 DConAddr; 147 147 148 148 // a key class used to identify DConnectStub objects stored in a hash table -
trunk/src/libs/xpcom18a4/xpcom/base/nscore.h
r11440 r21113 431 431 #endif 432 432 433 #ifndef VBOX 433 434 /* 434 435 * Use these macros to do 64bit safe pointer conversions. … … 437 438 #define NS_PTR_TO_INT32(x) ((char *)(x) - (char *)0) 438 439 #define NS_INT32_TO_PTR(x) ((void *)((char *)0 + (x))) 440 #else /* VBOX */ 441 // This stuff is (contrary to the comment) totally 64bit unsafe, so strip 442 // it down to only do one direction, which is used by the hashing code. 443 #define NS_PTR_TO_INT32(x) ((PRInt32)((char *)(x) - (char *)0)) 444 #endif /* VBOX */ 439 445 440 446 /* -
trunk/src/libs/xpcom18a4/xpcom/ds/nsCheapSets.h
r1 r21113 83 83 84 84 private: 85 typedef unsigned longPtrBits;85 typedef PRUint64 PtrBits; 86 86 87 87 /** Get the hash pointer (or null if we're not a hash) */ … … 156 156 157 157 private: 158 typedef unsigned longPtrBits;158 typedef PRUint64 PtrBits; 159 159 160 160 /** Get the hash pointer (or null if we're not a hash) */ -
trunk/src/libs/xpcom18a4/xpcom/ds/nsVoidArray.h
r1 r21113 376 376 377 377 private: 378 typedef unsigned longPtrBits;378 typedef PRUint64 PtrBits; 379 379 380 380 PRBool HasSingleChild() const -
trunk/src/libs/xpcom18a4/xpcom/io/nsFastLoadService.cpp
r1 r21113 395 395 return rv; 396 396 397 #ifndef VBOX 397 398 mChecksumTable.Put(&key, NS_INT32_TO_PTR(checksum)); 399 #else /* VBOX */ 400 mChecksumTable.Put(&key, (void *)checksum); 401 #endif /* VBOX */ 398 402 *aChecksum = checksum; 399 403 return NS_OK; … … 418 422 419 423 nsCStringKey key(path); 424 #ifndef VBOX 420 425 mChecksumTable.Put(&key, NS_INT32_TO_PTR(checksum)); 426 #else /* VBOX */ 427 mChecksumTable.Put(&key, (void *)checksum); 428 #endif /* VBOX */ 421 429 return NS_OK; 422 430 }
Note:
See TracChangeset
for help on using the changeset viewer.