2nd parameter of Gestalt() is SInt32, not long. 64-bit fix. b=514996 r=josh

This commit is contained in:
Makoto Kato 2009-09-18 12:37:22 -04:00
parent 2dbe5949ee
commit c59b27822d
2 changed files with 2 additions and 2 deletions

View File

@ -1657,7 +1657,7 @@ nsChromeRegistry::ProcessManifestBuffer(char *buf, PRInt32 length,
info.dwMinorVersion);
}
#elif defined(XP_MACOSX)
long majorVersion, minorVersion;
SInt32 majorVersion, minorVersion;
if ((Gestalt(gestaltSystemVersionMajor, &majorVersion) == noErr) &&
(Gestalt(gestaltSystemVersionMinor, &minorVersion) == noErr)) {
nsTextFormatter::ssprintf(osVersion, NS_LITERAL_STRING("%ld.%ld").get(),

View File

@ -106,7 +106,7 @@ NS_IMETHODIMP nsNativeAppSupportCocoa::Start(PRBool *_retval)
{
NS_OBJC_BEGIN_TRY_ABORT_BLOCK_NSRESULT;
long response = 0;
SInt32 response = 0;
OSErr err = ::Gestalt (gestaltSystemVersion, &response);
response &= 0xFFFF; // The system version is in the low order word