This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
FYI: define PY_SSIZE_T_CLEAN
- From: Tom Tromey <tromey at redhat dot com>
- To: gdb-patches at sourceware dot org
- Date: Tue, 28 Jun 2011 07:08:58 -0600
- Subject: FYI: define PY_SSIZE_T_CLEAN
I'm checking this in on the trunk.
David Malcolm pointed out that it is best to define PY_SSIZE_T_CLEAN;
and now that we are using Py_ssize_t as the type of an argument to
PyArg_ParseTupleAndKeywords, we need to.
Built and regtested by the buildbot.
Tom
2011-06-28 Tom Tromey <tromey@redhat.com>
* python/python-internal.h (PY_SSIZE_T_CLEAN): Define.
Index: python/python-internal.h
===================================================================
RCS file: /cvs/src/src/gdb/python/python-internal.h,v
retrieving revision 1.45
diff -u -r1.45 python-internal.h
--- python/python-internal.h 27 May 2011 18:39:49 -0000 1.45
+++ python/python-internal.h 28 Jun 2011 13:06:41 -0000
@@ -41,6 +41,9 @@
around technique as above. */
#undef _FILE_OFFSET_BITS
+/* Request clean size types from Python. */
+#define PY_SSIZE_T_CLEAN
+
/* Include the Python header files using angle brackets rather than
double quotes. On case-insensitive filesystems, this prevents us
from including our python/python.h header file. */