Skip to content

_PyMem_FreeDelayed() missing a NULL pointer check #131719

Closed

Description

@tom-pytel

Bug report

Bug description:

Normally this is not a problem but if _PyMem_FreeDelayed(NULL) is called an (quite!) improbably high number of times in a single thread it can lead to memory exhaustion because the NULL is added to a queue. Fix is just to add a NULL check like _PyObject_XDecRefDelayed().

CPython versions tested on:

3.14

Operating systems tested on:

No response

Linked PRs

Activity

  1. added a commit that references this issue on Mar 25, 2025
  2. added a commit that references this issue on Mar 25, 2025
  3. added a commit that references this issue on Mar 25, 2025
  4. added a commit that references this issue on Mar 25, 2025
  5. added a commit that references this issue on Apr 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    type-bugAn unexpected behavior, bug, or error

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions