]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Fix double use of f.close().
authorÉric Araujo <merwok@netwok.org>
Fri, 15 Apr 2011 22:13:39 +0000 (00:13 +0200)
committerÉric Araujo <merwok@netwok.org>
Fri, 15 Apr 2011 22:13:39 +0000 (00:13 +0200)
The other one is in a finally block not seen in the diff, which I added
in 3bf86785cd9c (for #10252).

Lib/sysconfig.py

index 685c84ea5ef9913ce0fa561d700f91c18f08e7df..3b0ca85fbbc11744b7adbf317414af2140a7c309 100644 (file)
@@ -694,7 +694,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