summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesse Noller <jnoller@gmail.com>2009-03-31 22:25:20 (GMT)
committerJesse Noller <jnoller@gmail.com>2009-03-31 22:25:20 (GMT)
commit70b11f0f97c45b0e712c00d00d8f7f891ebab99e (patch)
tree4ad147b2bc91d2ad70278c3452bbb2de49f277a1
parent61611f84c91b3cd6d70e8f554efcef243f3413d1 (diff)
downloadcpython-70b11f0f97c45b0e712c00d00d8f7f891ebab99e.zip
cpython-70b11f0f97c45b0e712c00d00d8f7f891ebab99e.tar.gz
cpython-70b11f0f97c45b0e712c00d00d8f7f891ebab99e.tar.bz2
Merged revisions 70908 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r70908 | jesse.noller | 2009-03-31 17:20:35 -0500 (Tue, 31 Mar 2009) | 1 line Issue 5619: Pass MS CRT debug flags into subprocesses ........
-rw-r--r--Misc/ACKS1
-rw-r--r--Misc/NEWS3
-rw-r--r--Modules/_multiprocessing/win32_functions.c6
-rw-r--r--Python/pythonrun.c2
4 files changed, 12 insertions, 0 deletions
diff --git a/Misc/ACKS b/Misc/ACKS
index a0166a5..79b7467 100644
--- a/Misc/ACKS
+++ b/Misc/ACKS
@@ -674,6 +674,7 @@ Daniel Stutzbach
Nathan Sullivan
Mark Summerfield
Hisao Suzuki
+Andrew Svetlov
Kalle Svensson
Paul Swartz
Thenault Sylvain
diff --git a/Misc/NEWS b/Misc/NEWS
index 21268fe..d6bc73a 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -92,6 +92,9 @@ Core and Builtins
Library
-------
+- Issue #5619: Multiprocessing children disobey the debug flag and causes
+ popups on windows buildbots. Patch applied to work around this issue.
+
- Issue #5632: Thread.ident was None for the main thread and threads not created
with the threading module.
diff --git a/Modules/_multiprocessing/win32_functions.c b/Modules/_multiprocessing/win32_functions.c
index 513fc02..549c151 100644
--- a/Modules/_multiprocessing/win32_functions.c
+++ b/Modules/_multiprocessing/win32_functions.c
@@ -130,6 +130,12 @@ win32_ExitProcess(PyObject *self, PyObject *args)
if (!PyArg_ParseTuple(args, "I", &uExitCode))
return NULL;
+ #if defined(Py_DEBUG)
+ SetErrorMode(SEM_FAILCRITICALERRORS|SEM_NOALIGNMENTFAULTEXCEPT|SEM_NOGPFAULTERRORBOX|SEM_NOOPENFILEERRORBOX);
+ _CrtSetReportMode(_CRT_ASSERT, _CRTDBG_MODE_DEBUG);
+ #endif
+
+
ExitProcess(uExitCode);
return NULL;
diff --git a/Python/pythonrun.c b/Python/pythonrun.c
index f2cd819..38db290 100644
--- a/Python/pythonrun.c
+++ b/Python/pythonrun.c
@@ -1631,6 +1631,8 @@ void
Py_FatalError(const char *msg)
{
fprintf(stderr, "Fatal Python error: %s\n", msg);
+ fflush(stderr); /* it helps in Windows debug build */
+
#ifdef MS_WINDOWS
{
size_t len = strlen(msg);