Skip to content

Conversation

NathanFreeman
Copy link
Contributor

@NathanFreeman NathanFreeman commented Aug 18, 2021

A process a want to create /home/test/a directory.
Another process b want to create /home/test/b directory.
But process b will fail rather than creating /home/test/b directory if /home/test/ directory had created by process a.
So I optimize php_plain_files_mkdir function to improve the success rate.

@nikic
I am so sorry.
I issued a new pr and closed old pr because of my unintentional operation.
I hope it won't cause any inconvenience.

Thanks.

php_error_docref(NULL, E_WARNING, "%s", strerror(errno));
}
if (ret < 0 && errno != EEXIST) {
/* stop running and issue a warning to client when ret < 0 and errno != EEXIST */
Copy link
Member

Choose a reason for hiding this comment

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

Can you please keep the options & REPORT_ERRORS check here?

Copy link
Member

Choose a reason for hiding this comment

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

And could you please switch the indentation from spaces -> tabs?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Can you please keep the options & REPORT_ERRORS check here?

Fix it. Thanks foy your code review.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

And could you please switch the indentation from spaces -> tabs?

Fix it. Thanks foy your code review.

@Jehong-Ahn
Copy link

Let's add this to 7.x, too.

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