diff options
author | Dirkjan Ochtman <djc@gentoo.org> | 2011-10-07 10:55:51 +0000 |
---|---|---|
committer | Dirkjan Ochtman <djc@gentoo.org> | 2011-10-07 10:55:51 +0000 |
commit | a5f020b377bd47cafc57d75f34bec6df5a2a4504 (patch) | |
tree | 0ac2ed99ae6fa611722dbd033d510e89fe943477 /eclass/python.eclass | |
parent | Fix calculation of test hook function name in _python_test_hook(). (diff) | |
download | historical-a5f020b377bd47cafc57d75f34bec6df5a2a4504.tar.gz historical-a5f020b377bd47cafc57d75f34bec6df5a2a4504.tar.bz2 historical-a5f020b377bd47cafc57d75f34bec6df5a2a4504.zip |
Fix ResourceWarning in python_merge_intermediate_installation_images().
(Patch by Arfrever.)
Diffstat (limited to 'eclass/python.eclass')
-rw-r--r-- | eclass/python.eclass | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/eclass/python.eclass b/eclass/python.eclass index 10cc916b2937..a64f04bd2800 100644 --- a/eclass/python.eclass +++ b/eclass/python.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/python.eclass,v 1.136 2011/10/07 10:53:14 djc Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/python.eclass,v 1.137 2011/10/07 10:55:51 djc Exp $ # @ECLASS: python.eclass # @MAINTAINER: @@ -1623,7 +1623,9 @@ else: # Python 2 stdout = sys.stdout -files = set(open('${T}/python_wrapper_scripts', 'rb').read().rstrip(${b}'\x00').split(${b}'\x00')) +python_wrapper_scripts_file = open('${T}/python_wrapper_scripts', 'rb') +files = set(python_wrapper_scripts_file.read().rstrip(${b}'\x00').split(${b}'\x00')) +python_wrapper_scripts_file.close() for file in sorted(files): stdout.write(file) |