Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
c27b8b88
Commit
c27b8b88
authored
May 08, 2008
by
Ronald Oussoren
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix for issue 1770190: platform.mac_ver() now returns the right
version on OSX 10.4.10
parent
5a9fed75
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletion
+11
-1
Lib/platform.py
Lib/platform.py
+11
-1
No files found.
Lib/platform.py
View file @
c27b8b88
...
...
@@ -722,7 +722,17 @@ def mac_ver(release='',versioninfo=('','',''),machine=''):
major
=
(
sysv
&
0xFF00
)
>>
8
minor
=
(
sysv
&
0x00F0
)
>>
4
patch
=
(
sysv
&
0x000F
)
release
=
'%s.%i.%i'
%
(
_bcd2str
(
major
),
minor
,
patch
)
if
(
major
,
minor
)
>=
(
10
,
4
):
# the 'sysv' gestald cannot return patchlevels
# higher than 9. Apple introduced 3 new
# gestalt codes in 10.4 to deal with this
# issue (needed because patch levels can
# run higher than 9, such as 10.4.11)
major
,
minor
,
patch
=
_mac_ver_lookup
((
'sys1'
,
'sys2'
,
'sys3'
))
release
=
'%i.%i.%i'
%
(
major
,
minor
,
patch
)
else
:
release
=
'%s.%i.%i'
%
(
_bcd2str
(
major
),
minor
,
patch
)
if
sysu
:
major
=
int
((
sysu
&
0xFF000000
L
)
>>
24
)
minor
=
(
sysu
&
0x00F00000
)
>>
20
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment