[Python-checkins] python/dist/src/PC/bdist_wininst install.c,
1.1.14.6, 1.1.14.7
theller at users.sourceforge.net
theller at users.sourceforge.net
Wed Dec 22 16:35:26 CET 2004
Update of /cvsroot/python/python/dist/src/PC/bdist_wininst
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24200
Modified Files:
Tag: release23-maint
install.c
Log Message:
Backport a patch from Mark Hammond.
Partial fix for [1067732] - "wininst --install-script leaves residual
files on C:\"
'tempnam()' is used rather than 'tmpnam()' - 'tmpnam' creates a temp
file on the root of the current drive, and if this is readonly
explains the 'freopen' errors occasionally reported. 'tempnam' creates
the temp file in the %TEMP% directory.
Index: install.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/PC/bdist_wininst/install.c,v
retrieving revision 1.1.14.6
retrieving revision 1.1.14.7
diff -u -d -r1.1.14.6 -r1.1.14.7
--- install.c 22 Dec 2004 15:12:46 -0000 1.1.14.6
+++ install.c 22 Dec 2004 15:35:20 -0000 1.1.14.7
@@ -1708,7 +1708,7 @@
if (logfile)
fprintf(logfile, "300 Run Script: [%s]%s\n", pythondll, fname);
- tempname = tmpnam(NULL);
+ tempname = tempnam(NULL, NULL);
if (!freopen(tempname, "a", stderr))
MessageBox(GetFocus(), "freopen stderr", NULL, MB_OK);
@@ -2067,7 +2067,7 @@
argv[0] = scriptname;
- tempname = tmpnam(NULL);
+ tempname = tempnam(NULL, NULL);
if (!freopen(tempname, "a", stderr))
MessageBox(GetFocus(), "freopen stderr", NULL, MB_OK);
More information about the Python-checkins
mailing list