diff options
Diffstat (limited to 'python/libxslt.c')
-rw-r--r-- | python/libxslt.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/python/libxslt.c b/python/libxslt.c index dcf83e3a..5809c203 100644 --- a/python/libxslt.c +++ b/python/libxslt.c @@ -107,7 +107,7 @@ libxslt_xmlXPathFuncCallback(xmlXPathParserContextPtr ctxt, int nargs) { list = PyTuple_New(nargs + 1); PyTuple_SetItem(list, 0, libxml_xmlXPathParserContextPtrWrap(ctxt)); - for (i = 0;i < nargs;i++) { + for (i = nargs - 1;i >= 0;i--) { obj = valuePop(ctxt); cur = libxml_xmlXPathObjectPtrWrap(obj); PyTuple_SetItem(list, i + 1, cur); |