1--TEST--
2stream_copy_to_stream() from empty file
3--FILE--
4<?php
5
6$tmp_empty_file = __DIR__ . "/stream_copy_to_stream_empty.tmp";
7file_put_contents($tmp_empty_file, "");
8
9$in = fopen($tmp_empty_file, 'r');
10$out = fopen('php://memory', 'w');
11var_dump(stream_copy_to_stream($in, $out));
12
13?>
14--CLEAN--
15<?php
16unlink(__DIR__ . "/stream_copy_to_stream_empty.tmp");
17?>
18--EXPECT--
19int(0)
20