-
-
Notifications
You must be signed in to change notification settings - Fork 32.1k
Potential integer overflow in instrumentation.c #135177
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Labels
interpreter-core
(Objects, Python, Grammar, and Parser dirs)
type-bug
An unexpected behavior, bug, or error
Comments
rialbat
added a commit
to rialbat/cpython
that referenced
this issue
Jun 5, 2025
rialbat
added a commit
to rialbat/cpython
that referenced
this issue
Jun 6, 2025
… to handle potential integer overflow
rialbat
added a commit
to rialbat/cpython
that referenced
this issue
Jun 6, 2025
Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
rialbat
added a commit
to rialbat/cpython
that referenced
this issue
Jun 6, 2025
Clarified that we are referring to the int type in C. Co-authored-by: Victor Stinner <vstinner@python.org>
rialbat
added a commit
to rialbat/cpython
that referenced
this issue
Jun 6, 2025
…ential overflow Co-authored-by: Victor Stinner <vstinner@python.org>
rialbat
added a commit
to rialbat/cpython
that referenced
this issue
Jun 6, 2025
… to Py_ssize_t for type consistency in assert Co-authored-by: Victor Stinner <vstinner@python.org>
The number of instructions will not exceed |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
interpreter-core
(Objects, Python, Grammar, and Parser dirs)
type-bug
An unexpected behavior, bug, or error
Uh oh!
There was an error while loading. Please reload this page.
The arithmetic expression
to * (int)sizeof(_Py_CODEUNIT)
can overflow if the number of instructions in a function exceeds MAX_INT / 2, asto
represents the instruction offset andsizeof(_Py_CODEUNIT)
is 2.cpython/Python/instrumentation.c
Line 1239 in 4b44b34
Linked PRs
The text was updated successfully, but these errors were encountered: