We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a86fae2 commit 94ef249Copy full SHA for 94ef249
src/LibEvLoop.php
@@ -35,6 +35,10 @@ public function __construct()
35
*/
36
public function addReadStream($stream, callable $listener)
37
{
38
+ if (isset($this->readEvents[(int) $stream])) {
39
+ return;
40
+ }
41
+
42
$callback = function () use ($stream, $listener) {
43
call_user_func($listener, $stream, $this);
44
};
@@ -50,6 +54,10 @@ public function addReadStream($stream, callable $listener)
50
54
51
55
public function addWriteStream($stream, callable $listener)
52
56
57
+ if (isset($this->writeEvents[(int) $stream])) {
58
59
60
53
61
62
63
0 commit comments