From 44c9b2aba51f73e50c17b7f990a054d0d4804269 Mon Sep 17 00:00:00 2001 From: Dmitry Zagorny Date: Mon, 14 Sep 2015 13:00:55 -0500 Subject: Added closing for 'so_dup' and 'se_dup' file descriptors. Issue: _exec_command function doesn't close 'so_dup' and 'se_dup' file descriptors.SciPy try to build scipy\special\amos\zunik.f and crash:error: Command "C:\Program Files (x86)\Intel\Composer XE 2015\bin\intel64\ifort.exe /nologo /MD /nbs /names:lowercase /assume:underscore /O1 -IC:\Python27\lib\site-packages\numpy\core\include -c /c scipy\special\amos\zunik.f /Fobuild\temp.win-amd64-2.7\scipy\special\amos\zunik.o" failed with exit status -1073741502 --- numpy/distutils/exec_command.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'numpy/distutils/exec_command.py') diff --git a/numpy/distutils/exec_command.py b/numpy/distutils/exec_command.py index f751a8ca3..9fa09cd51 100644 --- a/numpy/distutils/exec_command.py +++ b/numpy/distutils/exec_command.py @@ -441,8 +441,10 @@ def _exec_command( command, use_shell=None, use_tee = None, **env ): se_flush() if _so_has_fileno: os.dup2(so_dup, so_fileno) + os.close(so_dup) if _se_has_fileno: os.dup2(se_dup, se_fileno) + os.close(se_dup) fout.close() fout = open_latin1(outfile, 'r') -- cgit v1.2.1