Skip to content

BUG: Fix PyArray_ZeroContiguousBuffer (resize) with struct dtypes#27229

Merged
charris merged 1 commit intonumpy:maintenance/2.1.xfrom
charris:backport-27226
Aug 16, 2024
Merged

BUG: Fix PyArray_ZeroContiguousBuffer (resize) with struct dtypes#27229
charris merged 1 commit intonumpy:maintenance/2.1.xfrom
charris:backport-27226

Conversation

@charris
Copy link
Member

@charris charris commented Aug 16, 2024

Backport of #27226.

We allow the structured dtype to return NULL for the zero fill function to indicate that a simple memset is sufficient.

Also simplifies error handling a bit. The get_fill_zero_loop function must clean up on error and not return references if returns a NULL loop.

Closes #27225.

We allow the structured dtype to return NULL for the zero fill
function to indicate that a simple memset is sufficient.

Also simplifies error handling a bit.  The get_fill_zero_loop
function must clean up on error and not return references if
returns a `NULL` loop.
@charris charris added 00 - Bug 08 - Backport Used to tag backport PRs labels Aug 16, 2024
@charris charris added this to the 2.1.0 release milestone Aug 16, 2024
@charris charris merged commit c080180 into numpy:maintenance/2.1.x Aug 16, 2024
@charris charris deleted the backport-27226 branch August 16, 2024 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

00 - Bug 08 - Backport Used to tag backport PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants