summaryrefslogtreecommitdiffstats
path: root/PC
diff options
context:
space:
mode:
authorSteve Dower <steve.dower@microsoft.com>2015-04-12 04:26:27 (GMT)
committerSteve Dower <steve.dower@microsoft.com>2015-04-12 04:26:27 (GMT)
commit8fc8980c96f58a7f06e4e3133735807bd245c658 (patch)
tree04376ea1928a20c88b506e836ab82cc266cc85ae /PC
parentfe0a41aae425c61364b79c18ca8321dffed3ac40 (diff)
downloadcpython-8fc8980c96f58a7f06e4e3133735807bd245c658.zip
cpython-8fc8980c96f58a7f06e4e3133735807bd245c658.tar.gz
cpython-8fc8980c96f58a7f06e4e3133735807bd245c658.tar.bz2
Issue #23524: Replace _PyVerify_fd function with calls to _set_thread_local_invalid_parameter_handler.
Diffstat (limited to 'PC')
-rw-r--r--PC/invalid_parameter_handler.c4
-rw-r--r--PC/msvcrtmodule.c2
2 files changed, 4 insertions, 2 deletions
diff --git a/PC/invalid_parameter_handler.c b/PC/invalid_parameter_handler.c
index 3bc0104..d634710 100644
--- a/PC/invalid_parameter_handler.c
+++ b/PC/invalid_parameter_handler.c
@@ -15,8 +15,8 @@ static void __cdecl _silent_invalid_parameter_handler(
unsigned int line,
uintptr_t pReserved) { }
-void *_Py_silent_invalid_parameter_handler =
- (void*)_silent_invalid_parameter_handler;
+_invalid_parameter_handler _Py_silent_invalid_parameter_handler = _silent_invalid_parameter_handler;
+
#endif
#endif
diff --git a/PC/msvcrtmodule.c b/PC/msvcrtmodule.c
index 18dec6d..c8345c5 100644
--- a/PC/msvcrtmodule.c
+++ b/PC/msvcrtmodule.c
@@ -149,7 +149,9 @@ msvcrt_get_osfhandle(PyObject *self, PyObject *args)
if (!_PyVerify_fd(fd))
return PyErr_SetFromErrno(PyExc_IOError);
+ _Py_BEGIN_SUPPRESS_IPH
handle = _get_osfhandle(fd);
+ _Py_END_SUPPRESS_IPH
if (handle == -1)
return PyErr_SetFromErrno(PyExc_IOError);