diff --git a/CHANGELOG b/CHANGELOG index 5f61fe7..c7f0e11 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,8 @@ +### 1.0.9 + +- Fix NativeReactor not ending up in stopped state if primary + callback didn't install any events. + ### 1.0.8 - Fix NativeReactor running a busy loop if no timers are active. diff --git a/lib/NativeReactor.php b/lib/NativeReactor.php index 34d274a..206035a 100644 --- a/lib/NativeReactor.php +++ b/lib/NativeReactor.php @@ -58,6 +58,7 @@ class NativeReactor implements Reactor { $this->state = self::STARTING; $watcherId = $this->immediately($onStart); if (!$this->tryImmediate($this->watchers[$watcherId]) || empty($this->keepAliveCount)) { + $this->state = self::STOPPED; return; } } else {