From dbd6503e97264938c8fb4ce099c64da7a475e12e Mon Sep 17 00:00:00 2001 From: Jack Jansen Date: Thu, 17 Apr 2003 22:01:10 +0000 Subject: [PATCH] dded missing k and K format specifiers to Py_BuildValue and friends. --- Python/modsupport.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Python/modsupport.c b/Python/modsupport.c index 9725a1bd020..12f3f17b487 100644 --- a/Python/modsupport.c +++ b/Python/modsupport.c @@ -289,9 +289,15 @@ do_mkvalue(char **p_format, va_list *p_va) case 'l': return PyInt_FromLong((long)va_arg(*p_va, long)); + case 'k': + return PyInt_FromLong((long)va_arg(*p_va, unsigned long)); + #ifdef HAVE_LONG_LONG case 'L': return PyLong_FromLongLong((PY_LONG_LONG)va_arg(*p_va, PY_LONG_LONG)); + + case 'K': + return PyLong_FromLongLong((PY_LONG_LONG)va_arg(*p_va, unsigned PY_LONG_LONG)); #endif #ifdef Py_USING_UNICODE case 'u':