1--TEST--
2Bug #41518 (file_exists() warns of open_basedir restriction on non-existent file)
3--SKIPIF--
4<?php
5$tmp_dir = __DIR__ . '/bug41518';
6mkdir($tmp_dir);
7if (!is_dir($tmp_dir)) {
8    die("skip");
9}
10@unlink($tmp_dir);
11?>
12--INI--
13open_basedir=.
14--FILE--
15<?php
16
17$tmp_dir = __DIR__ . "/bug41518/";
18@mkdir($tmp_dir);
19$tmp_file = $tmp_dir."/bug41418.tmp";
20
21touch($tmp_file);
22var_dump(file_exists($tmp_file)); //exists
23var_dump(file_exists($tmp_file."nosuchfile")); //doesn't exist
24
25@unlink($tmp_file);
26@rmdir($tmp_dir);
27echo "Done\n";
28?>
29--CLEAN--
30<?php
31$tmp_dir = __DIR__ . "/bug41518/";
32@unlink($tmp_dir);
33?>
34--EXPECT--
35bool(true)
36bool(false)
37Done
38