From f9876fd931a9543251456b5dbd464546816156a1 Mon Sep 17 00:00:00 2001 From: "William M. Brack" Date: Thu, 25 Oct 2007 00:43:22 +0000 Subject: [PATCH] changed iterator argument for Py_Dict_Next from int to ssize_t to fix * python/libxslt.c: changed iterator argument for Py_Dict_Next from int to ssize_t to fix x86_64 bug #489854 svn path=/trunk/; revision=1447 --- ChangeLog | 6 ++++++ python/libxslt.c | 10 ++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 81cdc3e..3f329a4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Wed Oct 24 17:41:08 PDT 2007 William Brack + + * python/libxslt.c: changed iterator argument for Py_Dict_Next + from int to ssize_t (seems Python docs are incorrect) to fix + x86_64 bug #489854. + Wed Oct 10 16:33:09 CEST 2007 Daniel Veillard * libexslt/date.c tests/exslt/date/datetime.1.out diff --git a/python/libxslt.c b/python/libxslt.c index 32bec4c..1cf573d 100644 --- a/python/libxslt.c +++ b/python/libxslt.c @@ -666,7 +666,8 @@ libxslt_xsltApplyStylesheetUser(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) PyObject *pyobj_params; PyObject *pyobj_transformCtxt; const char **params = NULL; - int len = 0, i = 0, j; + int len = 0, i, j; + ssize_t ppos = 0; PyObject *name; PyObject *value; @@ -686,7 +687,7 @@ libxslt_xsltApplyStylesheetUser(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) return(Py_None); } j = 0; - while (PyDict_Next(pyobj_params, &i, &name, &value)) { + while (PyDict_Next(pyobj_params, &ppos, &name, &value)) { const char *tmp; int size; @@ -740,7 +741,8 @@ libxslt_xsltApplyStylesheet(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) { PyObject *pyobj_doc; PyObject *pyobj_params; const char **params = NULL; - int len = 0, i = 0, j, params_size; + int len = 0, i, j, params_size; + ssize_t ppos = 0; PyObject *name; PyObject *value; @@ -761,7 +763,7 @@ libxslt_xsltApplyStylesheet(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) { } memset(params, 0, params_size); j = 0; - while (PyDict_Next(pyobj_params, &i, &name, &value)) { + while (PyDict_Next(pyobj_params, &ppos, &name, &value)) { const char *tmp; int size; -- 2.7.4