Skip to content
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

gh-86179: Avoid making case-only changes when calculating realpath() during initialization #113077

Merged
merged 1 commit into from Dec 14, 2023

Conversation

zooba
Copy link
Member

@zooba zooba commented Dec 14, 2023

@zooba
Copy link
Member Author

zooba commented Dec 14, 2023

!buildbot windows

@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by @zooba for commit a56fac8 🤖

The command will test the builders whose names match following regular expression: windows

The builders matched are:

  • AMD64 Windows11 Bigmem PR
  • AMD64 Windows Server 2022 NoGIL PR
  • AMD64 Windows11 Refleaks PR
  • AMD64 Windows10 PR
  • ARM64 Windows Non-Debug PR
  • AMD64 Windows11 Non-Debug PR
  • ARM64 Windows PR

@@ -535,7 +540,11 @@ getpath_realpath(PyObject *Py_UNUSED(self) , PyObject *args)
len -= 4;
}
}
result = PyUnicode_FromWideChar(p, len);
if (CompareStringOrdinal(path, (int)pathlen, p, len, TRUE) == CSTR_EQUAL) {
Copy link
Member

Choose a reason for hiding this comment

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

Can pathlen be larger than INT_MAX?

Copy link
Member Author

Choose a reason for hiding this comment

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

No, and if it is, we'll have failed earlier because the API can't handle more than 32K worth of path.

@zooba zooba merged commit fd81afc into python:main Dec 14, 2023
37 checks passed
@zooba zooba deleted the gh-86179 branch December 14, 2023 15:18
corona10 pushed a commit to corona10/cpython that referenced this pull request Dec 15, 2023
aisk pushed a commit to aisk/cpython that referenced this pull request Feb 11, 2024
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.

None yet

3 participants