-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Virtual cwd refactoring #15524
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
base: master
Are you sure you want to change the base?
Virtual cwd refactoring #15524
Conversation
d74be08
to
01b27a3
Compare
oldnamew = php_win32_ioutil_any_to_w(oldnamea); | ||
oldnamew = php_win32_ioutil_conv_any_to_w(old_name_a, old_name_a_len, PHP_WIN32_CP_IGNORE_LEN_P); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cmb69 as don't have a Windows machine and can't test it, is such a function call change even sensible or not?
And if yes, can I also provide a size_t
pointer for the 3rd argument so that PHP_WIN32_IOUTIL_CHECK_PATH_W()
doesn't need to make a call to wstrlen()
?
As seemingly this changes the behaviour of some tests in ways that I don't totally understand.
01b27a3
to
95d2fc5
Compare
95d2fc5
to
5194bd9
Compare
I'm not sure whether doing this change in zend_virtual_cwd.c now is a good idea. According to "Make it work, make it right, make it fast", we shouldn't skip the second step. That code is really contrieved, and especially |
I'll chip at this when I have motivation, as passing only a |
Commits should be reviewed individually.
Motivation
There are two primary motivations:
strlen()
when we already know itint
to convey meaning and intentTo achieve this, refactoring is conducted one step at a time on the various layers that interact with each other:
Some other/unrelated minor refactorings are likely going to happen in some commits when I encounter some oddities.