Skip to content

Commit 1b78121

Browse files
authored
Fix tempnam() path in test when running from out-of-source (#14326)
This fixes test when running the test from unusual paths such as in out-of-source builds: ```sh mkdir php-build cd php-build ../buildconf ../configure make ./sapi/cli/php ../run-tests.php ../ext/standard/tests/file/002.phpt ```
1 parent 8a24e31 commit 1b78121

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/standard/tests/file/002.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ blah blah blah blah blah blah blah
2222
blah blah blah blah blah blah blah
2323
EOD;
2424

25-
$name = tempnam("./ext/standard/tests/file/", "php");
25+
$name = tempnam(__DIR__, "php");
2626
$fp = fopen($name, "w");
2727
fwrite($fp, $data);
2828
fclose($fp);

0 commit comments

Comments
 (0)