summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2015-02-11 13:23:46 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2015-02-11 13:23:46 (GMT)
commit385efb4d9942ad483c7f866633ee735a2ec5003f (patch)
tree1cbeb461435682a4693b87b7d1a201da9ff780a3 /Modules
parenteb6b554fbc96a3d2f09e9486ac90352b9a8632af (diff)
parent7a5567a92cf0e0bcaae7dca8975328c9151fe1c7 (diff)
downloadcpython-385efb4d9942ad483c7f866633ee735a2ec5003f.zip
cpython-385efb4d9942ad483c7f866633ee735a2ec5003f.tar.gz
cpython-385efb4d9942ad483c7f866633ee735a2ec5003f.tar.bz2
Merge 3.4 (faulthandler)
Diffstat (limited to 'Modules')
-rw-r--r--Modules/faulthandler.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/Modules/faulthandler.c b/Modules/faulthandler.c
index 568724b..6f7c71d 100644
--- a/Modules/faulthandler.c
+++ b/Modules/faulthandler.c
@@ -927,12 +927,12 @@ faulthandler_fatal_error_py(PyObject *self, PyObject *args)
}
#if defined(HAVE_SIGALTSTACK) && defined(HAVE_SIGACTION)
-static void*
-stack_overflow(void *min_sp, void *max_sp, size_t *depth)
+static Py_uintptr_t
+stack_overflow(Py_uintptr_t min_sp, Py_uintptr_t max_sp, size_t *depth)
{
/* allocate 4096 bytes on the stack at each call */
unsigned char buffer[4096];
- void *sp = &buffer;
+ Py_uintptr_t sp = (Py_uintptr_t)&buffer;
*depth += 1;
if (sp < min_sp || max_sp < sp)
return sp;
@@ -945,7 +945,8 @@ static PyObject *
faulthandler_stack_overflow(PyObject *self)
{
size_t depth, size;
- char *sp = (char *)&depth, *stop;
+ Py_uintptr_t sp = (Py_uintptr_t)&depth;
+ Py_uintptr_t stop;
faulthandler_suppress_crash_report();
depth = 0;