1--TEST--
2Bug #47997 (stream_copy_to_stream returns 1 on empty streams)
3--INI--
4allow_url_fopen=1
5--FILE--
6<?php
7
8$in = fopen('data://text/plain,', 'rb+');
9$out = fopen('php://memory', 'wb+');
10
11var_dump(stream_copy_to_stream($in, $out));
12
13?>
14--EXPECT--
15int(0)
16