Take address before casting to avoid confusing the gcc optimizer with what perhaps shouldn't compile anyway. r=pinkerton sr=sfraser b=108585

This commit is contained in:
dbaron%fas.harvard.edu 2001-11-06 06:15:40 +00:00
parent 6d232445db
commit 65a4025f4e

View File

@ -348,7 +348,7 @@ NS_METHOD nsMenuX::AddMenu(nsIMenu * aMenu)
::DisableMenuItem(mMacMenuHandle, currItemIndex);
MenuHandle childMenu;
if (aMenu->GetNativeData(&(void*)childMenu) == NS_OK)
if (aMenu->GetNativeData((void**)&childMenu) == NS_OK)
::SetMenuItemHierarchicalMenu((MenuHandle) mMacMenuHandle, currItemIndex, childMenu);
return NS_OK;