gh-134768: Fix definition of mt_continue_should_break() (#134769)

In 121ed71f4e, mt_continue_should_break
was changed to be guarded by `Py_DEBUG`, but it's used in `compress_mt_continue_lock_held`
with just `assert`, so it needs to be available when `NDEBUG` is undefined
too.

`Py_DEBUG` implies `NDEBUG` is undefined, so we can check just that.

Fixes: 121ed71f4e
This commit is contained in:
Sam James 2025-05-30 05:42:19 +01:00 committed by GitHub
parent 5f60d0fccc
commit 2f2bee2111
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -512,7 +512,7 @@ compress_lock_held(ZstdCompressor *self, Py_buffer *data,
return NULL;
}
#ifdef Py_DEBUG
#ifndef NDEBUG
static inline int
mt_continue_should_break(ZSTD_inBuffer *in, ZSTD_outBuffer *out)
{