aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRonny Pfannschmidt <Ronny.Pfannschmidt@gmx.de>2012-04-09 11:39:51 +0200
committerRonny Pfannschmidt <Ronny.Pfannschmidt@gmx.de>2012-04-09 11:39:51 +0200
commit70c00c20a6a023001be274c2ddedfc840e976f64 (patch)
tree8873558b40c617e6995001a2838c8c1da67b2da3 /testrunner
parentupgrade py and _pytest to current tip (diff)
parentfix test for 32 bit platforms (diff)
downloadpypy-70c00c20a6a023001be274c2ddedfc840e976f64.tar.gz
pypy-70c00c20a6a023001be274c2ddedfc840e976f64.tar.bz2
pypy-70c00c20a6a023001be274c2ddedfc840e976f64.zip
merge from default
Diffstat (limited to 'testrunner')
-rw-r--r--testrunner/runner.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/testrunner/runner.py b/testrunner/runner.py
index 81782243c4..303dba81cb 100644
--- a/testrunner/runner.py
+++ b/testrunner/runner.py
@@ -24,13 +24,16 @@ if sys.platform == 'win32':
#Try to avoid opeing a dialog box if one of the tests causes a system error
import ctypes
winapi = ctypes.windll.kernel32
+ SetErrorMode = winapi.SetErrorMode
+ SetErrorMode.argtypes=[ctypes.c_int]
+
SEM_FAILCRITICALERRORS = 1
SEM_NOGPFAULTERRORBOX = 2
SEM_NOOPENFILEERRORBOX = 0x8000
flags = SEM_FAILCRITICALERRORS | SEM_NOGPFAULTERRORBOX | SEM_NOOPENFILEERRORBOX
#Since there is no GetErrorMode, do a double Set
- old_mode = winapi.SetErrorMode(flags)
- winapi.SetErrorMode(old_mode | flags)
+ old_mode = SetErrorMode(flags)
+ SetErrorMode(old_mode | flags)
SIGKILL = SIGTERM = 0
READ_MODE = 'rU'