Re: Finding out OS version
Re: Finding out OS version
- Subject: Re: Finding out OS version
- From: Lloyd Dupont <email@hidden>
- Date: Tue, 10 Jun 2003 09:31:37 +1000
SInt32 vers;
Gestalt(gestaltSystemVersion, &vers);
ret->OSName = [[NSString stringWithFormat:@"MacOS X %x.%x.%x",
(int) (vers >> 8),
(int) ((vers >> 4) & 0xF),
(int) (vers & 0xF)]
retain];
On Monday, June 9, 2003, at 08:45 PM, Tim Hewett wrote:
>
Hello,
>
>
I need to modify my software to work under 10.1 as well as 10.2.
>
At the moment it crashes under 10.1 as it uses the promised files
>
API, which 10.1 doesn't appear to support.
>
>
I'd prefer not to have a separate build for each OS, it would be
>
better for the program to detect it is using 10.1 and so disable
>
the features making use of promised files, but having searched
>
the Cocoa help documentation I can't find a way to do it. The
>
NSProcessInfo class has a method to return the OS version
>
string but the documentation specifically states that it is not
>
suitable for parsing...
>
>
Anyone else hit this problem? Is there some method hidden
>
away somewhere which gives the OS version in a format which
>
software can use for decision making?
>
>
Regards,
>
>
Tim Hewett.
>
_______________________________________________
>
cocoa-dev mailing list | email@hidden
>
Help/Unsubscribe/Archives:
>
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
>
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.