-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Only use realpath for real directories #26058
Conversation
In some cross-local-storage use cases, the Local storage is instantiated with "/" as data directory. In such cases, calling realpath() would cause PHP warnings when open_basedir is set. This fix bypasses the realpath() call when dealing with a root storage.
@PVince81, thanks for your PR! By analyzing the annotation information on this pull request, we identified @icewind1991, @DeepDiver1975 and @nickvergessen to be potential reviewers |
👍 |
1 similar comment
👍 |
Thanks to @PVince81. I confirm that the code fix (which I manually copied into my 9.1.0) does work - for my case at least - at last no more such entries in my OC log! Oh yes - and it would be great if the fix will be in 9.1.1. |
Hmm I was wrong about the backports, seems only OC 9.1 is affected. |
stable9.1: #26060 @DeepDiver1975 can you kick/boot/reboot/... Jenkins ? Still the mysql error |
In some cross-local-storage use cases, the Local storage is instantiated with "/" as data directory. In such cases, calling realpath() would cause PHP warnings when open_basedir is set. This fix bypasses the realpath() call when dealing with a root storage. Downstreaming of owncloud/core#26058 Signed-off-by: Lukas Reschke <[email protected]>
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Description
In some cross-local-storage use cases, the Local storage is
instantiated with "/" as data directory. In such cases, calling
realpath() would cause PHP warnings when open_basedir is set.
This fix bypasses the realpath() call when dealing with a root storage.
This occurs mostly when overwriting files with Webdav because it will trigger the version code's version copying which is internally a cross-storage copy apparently.
Related Issue
Fixes #26033
Motivation and Context
See issue, mostly a PHP warning
How Has This Been Tested?
See steps in issue
Types of changes
Checklist:
(can't really automatically test due to calling PHP system function)
Backports
stable9stable8.2Please review @owncloud/filesystem @timreeves @DeepDiver1975 @butonic