- wxASSERT_MSG(DMNewDisplayModeList(nDisplayID, NULL, NULL, &nNumModes, &pModes) == noErr, wxT("Could not create a new display mode list") );
+ err = DMNewDisplayModeList(nDisplayID, NULL, NULL, &nNumModes, &pModes);
+ wxASSERT_MSG(err == noErr, wxT("Could not create a new display mode list") );