bpo-31577: Fix a crash in os.utime() in case of a bad ns argument#3752
Merged
Conversation
Contributor
|
Why not check the type of the tuple entries is |
Member
|
Returning non-int doesn't cause a crash. Actually non-int objects with |
serhiy-storchaka
approved these changes
Sep 12, 2018
Contributor
|
Thanks @orenmn for the PR, and @serhiy-storchaka for merging it 🌮🎉.. I'm working now to backport this PR to: 3.7. |
miss-islington
pushed a commit
to miss-islington/cpython
that referenced
this pull request
Sep 12, 2018
…ythonGH-3752) (cherry picked from commit 0bd1a2d) Co-authored-by: Oren Milman <orenmn@gmail.com>
|
GH-9222 is a backport of this pull request to the 3.7 branch. |
miss-islington
added a commit
that referenced
this pull request
Sep 12, 2018
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
posixmodule.c- add a check whetherPyNumber_Divmod()returned a 2-tuple.test_os.py- add tests to verify that the crash is no more.https://bugs.python.org/issue31577