Skip to content

Uses var (otherwise not used) as parameter to open file in CFFileUtilities #2814

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
Aug 24, 2020

Conversation

valeriyvan
Copy link
Contributor

No description provided.

@spevans
Copy link
Contributor

spevans commented Jun 4, 2020

@swift-ci please test

@valeriyvan valeriyvan changed the title Uses var (otherwise not used) as parameter to open file Uses var (otherwise not used) as parameter to open file in CFFileUtilities Jun 4, 2020
@spevans
Copy link
Contributor

spevans commented Jun 5, 2020

@swift-ci please test

@valeriyvan
Copy link
Contributor Author

ping

1 similar comment
@valeriyvan
Copy link
Contributor Author

ping

@millenomi
Copy link
Contributor

cc @niw This is the CF dual of your last patch — should it be 0666?

@niw
Copy link
Contributor

niw commented Aug 20, 2020

Actually, probably get mode by stat(2) for existing path is unnecessary at least on POSIX system, because mode (oflag) is used only when it is creating a new file by O_CREAT.
Therefore, the original code works as expected (but has unused mode,) also this patch works as expected.

I think it is preferred to not have unused mode for sure, so I think this change is reasonable.

@millenomi millenomi merged commit 2c32228 into swiftlang:master Aug 24, 2020
@valeriyvan valeriyvan deleted the CFFileUtilities branch August 25, 2020 09:01
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.

4 participants