Skip to content

Commit 06bca22

Browse files
committed
Attempt fix for windows
1 parent 3728253 commit 06bca22

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/Psalm/Internal/LanguageServer/ProtocolStreamReader.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ final class ProtocolStreamReader implements ProtocolReader
4444
public function __construct($input)
4545
{
4646
$input = new ReadableResourceStream($input);
47+
$input->reference();
4748
EventLoop::queue(
4849
function () use ($input): void {
4950
while ($this->is_accepting_new_requests) {
@@ -65,6 +66,7 @@ function () use ($input): void {
6566
$this->on(
6667
'close',
6768
static function () use ($input): void {
69+
$input->unreference();
6870
$input->close();
6971
},
7072
);

0 commit comments

Comments
 (0)