mirror of https://github.com/python/cpython
Fix double use of f.close().
The other one is in a finally block not seen in the diff, which I added in 3bf86785cd9c (for #10252).
This commit is contained in:
parent
4800d6470c
commit
b22e17b2d6
|
@ -639,7 +639,6 @@ def get_platform():
|
|||
m = re.search(
|
||||
r'<key>ProductUserVisibleVersion</key>\s*' +
|
||||
r'<string>(.*?)</string>', f.read())
|
||||
f.close()
|
||||
if m is not None:
|
||||
macrelease = '.'.join(m.group(1).split('.')[:2])
|
||||
# else: fall back to the default behaviour
|
||||
|
|
Loading…
Reference in New Issue