Skip to content

bpo-35972: _xxsubinterpreters: Fix potential integer truncation in channel_send() #11822

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

Merged
merged 2 commits into from
Feb 12, 2019

Conversation

izbyshev
Copy link
Contributor

@izbyshev izbyshev commented Feb 11, 2019

@vstinner
Copy link
Member

Since it's a private API and _xxsubinterpreters is a private module, I don't think that a NEWS entry is needed.

@ericsnowcurrently: Would you mind to review this fix?

Copy link
Member

@vstinner vstinner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Copy link
Member

@ericsnowcurrently ericsnowcurrently left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(marking so it doesn't get merged yet)

@bedevere-bot
Copy link

A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated.

Once you have made the requested changes, please leave a comment on this pull request containing the phrase I have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

@ericsnowcurrently
Copy link
Member

As noted on the tracker issue, LGTM. I have added a comment to _long_shared() about the consequence for 32-bit architectures. I'll merge this in a little while.

@ericsnowcurrently ericsnowcurrently merged commit 16f842d into python:master Feb 12, 2019
@izbyshev izbyshev deleted the xid-long branch February 12, 2019 16:11
@vstinner
Copy link
Member

    /* Note that this means the size of shareable ints is bounded by
     * sys.maxsize.  Hence on 32-bit architectures that is half the
     * size of maximum shareable ints on 64-bit.
     */

If you really need 64-bit on 32-bit system, you can use int64_t. But it means that you should change _PyCrossInterpreterData.data type.

@pablogsal
Copy link
Member

Buildbots have detected a leak of memory blocks in this PR. I have oppened:

https://bugs.python.org/issue35984

I do not have time to look into this until this night.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants