Skip to content

Commit

Permalink
fix for starting an EvHttpServer after EvenManager is active
Browse files Browse the repository at this point in the history
  • Loading branch information
Steve Dekorte authored and Steve Dekorte committed Dec 22, 2009
1 parent fb97865 commit d2e9b90
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
5 changes: 1 addition & 4 deletions addons/Socket/io/A0_EventManager.io
Original file line number Diff line number Diff line change
Expand Up @@ -121,9 +121,8 @@ EventManager do(
if(coro, coro resumeLater, self coro := coroFor(run); coro setLabel("EventManager"); coro resumeLater)
)

//doc EventManager run Runs the EventManger loop. Does not return.
//doc EventManager run Runs the EventManger loop. Does not return. Private - should only be called by resumeIfNeeded.
run := method(
if(coro == nil, resumeIfNeeded; return)
//Scheduler currentCoroutine setLabel("EventManager")
//writeln("EventManager run")
setShouldRun(true)
Expand All @@ -138,8 +137,6 @@ EventManager do(
)
*/

//listenUntilEvent

er := if(Coroutine yieldingCoros first, listen, if(listensUntilEvent, listenUntilEvent, listen))
er ifError(e, Exception raise("Unrecoverable Error in EventManager: " .. e description))

Expand Down
2 changes: 1 addition & 1 deletion addons/Socket/io/EvHttpServer.io
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ EvHttpServer do(
responseProto := EvOutResponse

run := method(
EventManager run
EventManager resumeIfNeeded
start
self
)
Expand Down

0 comments on commit d2e9b90

Please sign in to comment.