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

Fix detecting file as directory on zOS issue #8051 #8052

Merged
merged 3 commits into from Nov 17, 2020
Merged

Fix detecting file as directory on zOS issue #8051 #8052

merged 3 commits into from Nov 17, 2020

Conversation

mahdi-hm
Copy link
Contributor

sys/stat.h provides macros like S_ISDIR to test for a directory. The macro S_IFDIR should not be used in this way since it has different result on zOS(Always detecting file as directory as a consequence).

@acozzette
Copy link
Member

@mahdi-hosseini-moghaddam Thank you for sending this fix, but I think the one problem is that Windows doesn't seem to support the S_ISDIR macro. Maybe you could put in an ifdef to keep the old if condition for Windows builds?

@mahdi-hm
Copy link
Contributor Author

mahdi-hm commented Nov 17, 2020

@mahdi-hosseini-moghaddam Thank you for sending this fix, but I think the one problem is that Windows doesn't seem to support the S_ISDIR macro. Maybe you could put in an ifdef to keep the old if condition for Windows builds?

I didn't know that, Thank you for your comment. I will update that.

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