Skip to content

Commit b805d3f

Browse files
committed
Add warning about closed STDIN PHP bug
1 parent 60d453d commit b805d3f

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -833,6 +833,12 @@ mean it reached EOF.
833833
$stream = new ReadableResourceStream(STDIN, $loop, 8192);
834834
```
835835

836+
> PHP bug warning: If the PHP process has explicitly been started without a
837+
`STDIN` stream, then trying to read from `STDIN` may return data from
838+
another stream resource. This does not happen if you start this with an empty
839+
stream like `php test.php < /dev/null` instead of `php test.php <&-`.
840+
See [#81](https://github.com/reactphp/stream/issues/81) for more details.
841+
836842
### WritableResourceStream
837843

838844
The `WritableResourceStream` is a concrete implementation of the

0 commit comments

Comments
 (0)