File tree Expand file tree Collapse file tree 3 files changed +2
-21
lines changed
Expand file tree Collapse file tree 3 files changed +2
-21
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,6 @@ class LibEvLoop implements LoopInterface
1212 private $ readEvents = array ();
1313 private $ writeEvents = array ();
1414 private $ timers = array ();
15- private $ suspended = false ;
1615
1716 public function __construct ()
1817 {
@@ -138,21 +137,11 @@ public function tick()
138137
139138 public function run ()
140139 {
141- // @codeCoverageIgnoreStart
142- if ($ this ->suspended ) {
143- $ this ->suspended = false ;
144- $ this ->loop ->resume ();
145- } else {
146- $ this ->loop ->run ();
147- }
148- // @codeCoverageIgnoreEnd
140+ $ this ->loop ->run ();
149141 }
150142
151143 public function stop ()
152144 {
153- // @codeCoverageIgnoreStart
154- $ this ->loop ->suspend ();
155- $ this ->suspended = true ;
156- // @codeCoverageIgnoreEnd
145+ $ this ->loop ->breakLoop ();
157146 }
158147}
Original file line number Diff line number Diff line change @@ -226,15 +226,11 @@ public function tick()
226226
227227 public function run ()
228228 {
229- // @codeCoverageIgnoreStart
230229 event_base_loop ($ this ->base );
231- // @codeCoverageIgnoreEnd
232230 }
233231
234232 public function stop ()
235233 {
236- // @codeCoverageIgnoreStart
237234 event_base_loopexit ($ this ->base );
238- // @codeCoverageIgnoreEnd
239235 }
240236}
Original file line number Diff line number Diff line change @@ -156,19 +156,15 @@ public function tick()
156156
157157 public function run ()
158158 {
159- // @codeCoverageIgnoreStart
160159 $ this ->running = true ;
161160
162161 while ($ this ->tick ()) {
163162 // NOOP
164163 }
165- // @codeCoverageIgnoreEnd
166164 }
167165
168166 public function stop ()
169167 {
170- // @codeCoverageIgnoreStart
171168 $ this ->running = false ;
172- // @codeCoverageIgnoreEnd
173169 }
174170}
You can’t perform that action at this time.
0 commit comments