From: cui Date: Tue, 21 Apr 2026 19:49:44 +0000 (+0800) Subject: gh-146578: _zstd: Fix printf format for pledged size errors (#146576) X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=09233bd19879284395aff97d7357b693893e6dd7;p=thirdparty%2FPython%2Fcpython.git gh-146578: _zstd: Fix printf format for pledged size errors (#146576) Use %llu instead of %ull for unsigned long long in zstd_contentsize_converter ValueError messages. --- diff --git a/Modules/_zstd/compressor.c b/Modules/_zstd/compressor.c index f90bc9c5ab58..8a3cd182ab15 100644 --- a/Modules/_zstd/compressor.c +++ b/Modules/_zstd/compressor.c @@ -74,7 +74,7 @@ zstd_contentsize_converter(PyObject *size, unsigned long long *p) if (PyErr_ExceptionMatches(PyExc_OverflowError)) { PyErr_Format(PyExc_ValueError, "size argument should be a positive int less " - "than %ull", ZSTD_CONTENTSIZE_ERROR); + "than %llu", ZSTD_CONTENTSIZE_ERROR); return 0; } return 0; @@ -83,7 +83,7 @@ zstd_contentsize_converter(PyObject *size, unsigned long long *p) *p = ZSTD_CONTENTSIZE_ERROR; PyErr_Format(PyExc_ValueError, "size argument should be a positive int less " - "than %ull", ZSTD_CONTENTSIZE_ERROR); + "than %llu", ZSTD_CONTENTSIZE_ERROR); return 0; } *p = pledged_size;