1
0
mirror of https://github.com/danog/amp.git synced 2025-01-22 13:21:16 +01:00

Use same FD for read and write

This commit is contained in:
Aaron Piotrowski 2017-04-21 10:08:58 -05:00
parent ef51893b69
commit 6375d0881d

View File

@ -1384,11 +1384,11 @@ abstract class DriverTest extends TestCase {
$this->loop->disable($watcher);
$this->loop->enable($watcher1);
});
$watcher3 = $this->loop->onWritable($sockets[1], function ($watcher) use (&$invoked) {
$watcher3 = $this->loop->onWritable($sockets[0], function ($watcher) use (&$invoked) {
$invoked += 100;
$this->loop->disable($watcher);
});
$watcher4 = $this->loop->onWritable($sockets[1], function ($watcher) use (&$invoked, $watcher3) {
$watcher4 = $this->loop->onWritable($sockets[0], function ($watcher) use (&$invoked, $watcher3) {
$invoked += 1000;
$this->loop->disable($watcher);
$this->loop->enable($watcher3);