Skip to content

Commit 377b53c

Browse files
author
gollariel
committed
Update Connection.php
feof(): 41 is not a valid stream resource
1 parent 17044db commit 377b53c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Socket/Connection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ public function handleData($stream)
1515
$this->emit('data', array($data, $this));
1616
}
1717

18-
if ('' === $data || false === $data || feof($stream)) {
18+
if ('' === $data || false === $data || (is_resource($stream) && feof($stream))) {
1919
$this->end();
2020
}
2121
}

0 commit comments

Comments
 (0)