Author: Armin Rigo <ar...@tunes.org> Branch: Changeset: r486:d8f1d1089394 Date: 2012-06-22 22:59 +0200 http://bitbucket.org/cffi/cffi/changeset/d8f1d1089394/
Log: Fix the XXX. diff --git a/c/_ffi_backend.c b/c/_ffi_backend.c --- a/c/_ffi_backend.c +++ b/c/_ffi_backend.c @@ -2363,11 +2363,7 @@ PyErr_SetString(PyExc_ValueError, "negative array length"); return NULL; } -#ifdef MS_WIN32 - sprintf(extra_text, "[%ld]", (long)length); /* XXX not large enough */ -#else - sprintf(extra_text, "[%zd]", length); -#endif + sprintf(extra_text, "[%llu]", (unsigned PY_LONG_LONG)length); arraysize = length * ctitem->ct_size; if (length > 0 && (arraysize / length) != ctitem->ct_size) { PyErr_SetString(PyExc_OverflowError, _______________________________________________ pypy-commit mailing list pypy-commit@python.org http://mail.python.org/mailman/listinfo/pypy-commit