|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2017-06-28 18:42 UTC] requinix@php.net
-Status: Open
+Status: Not a bug
[2017-06-28 18:42 UTC] requinix@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 00:00:01 2025 UTC |
Description: ------------ Server: docker ubuntu14.04 php-fpm version:7.0.15 and 7.0.20 Nginx: 1.4.6 getcwd() incorrect output in register_shutdown_function() getcwd() returns wrong directory in register_shutdown_function(), only happens when using php-fpm or cgi. Bug not found in cli mode. Test script: --------------- <?php echo "Expected:" . getcwd() . "<br>"; register_shutdown_function(function () { echo "In shutdown function:" . getcwd() . "<br>"; }); // Output: // Expected:/var/www/html/test // In shutdown function:/ Expected result: ---------------- Expected:/var/www/html/test In shutdown function:/var/www/html/test Actual result: -------------- Expected:/var/www/html/test In shutdown function:/