Skip to content

[5.4] Fix temporary filename coda going above the maximum path length in some cases #3006

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 1 commit into from
Jul 13, 2021
Merged

Conversation

millenomi
Copy link
Contributor

This fixes an issue that would occur if the filename for a temporary file plus the .tmp. suffix was beyond the maximum path limit, but would be fine without it. This limits the temp filename to a maximum of 31 characters.

There will be follow-ups for other situations where long paths have similar issues, but this one specifically is also going to be nominated for 5.4.x and 5.5.

Fixes https://bugs.swift.org/browse/SR-14823. This is a candidate PR cherry-pick of #3005

… in some cases

This fixes an issue that would occur if the filename for a temporary file plus the .tmp.<coda> suffix was beyond the maximum path limit, but would be fine without it. This limits the temp filename to a maximum of 31 characters.

There will be follow-ups for other situations where long paths have similar issues, but this one specifically is also going to be nominated for 5.4.x and 5.5.

Fixes <https://bugs.swift.org/browse/SR-14823>.
@millenomi
Copy link
Contributor Author

cc @tomerd @drexin — nominated for 5.4.x.

@millenomi
Copy link
Contributor Author

@swift-ci please test

Copy link
Contributor

@drexin drexin left a comment

Choose a reason for hiding this comment

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

Thanks!

@millenomi millenomi merged commit ece97e7 into swiftlang:release/5.4 Jul 13, 2021
@millenomi millenomi deleted the pr/sr-14823-5.4 branch July 13, 2021 19:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants