[php-src] PR #25864: WIP: unify ZTS and NTS filesystem behaviour when possible
| From: | henderkes | Date: | Sat, 28 Nov 2026 04:54:09 +0000 |
| Subject: | [php-src] PR #25864: WIP: unify ZTS and NTS filesystem behaviour when possible | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-41146@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/25864
Author: henderkes
meaning, for now, on Linux.
calls unshare(CLONE_FS), which detaches the calling thread from the parent threads filesystem state.
This means a few things:
- virtual cwd isn't actually going through a virtual, emulated cwd anymore, but we use
NTS' direct kernel handling
- this does change behaviour slightly for e.g. symlink resolution
- FFI opening a library does now look in the real chdir
- we can chroot
- it's a lot faster for non-absolute paths :)
sadly dockers default security policy means this doesn't work in containers (by default)... not
sure what to do about that yet.