commit c53afd19ac8c84950ae8c4b496c36e017ce2675d Author: ellitron jdellit@stanford.edu Date: Fri May 27 01:24:21 2011 -0700
final changes before bed, too tired to recall --- return_of_the_rtmfpcat.as | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/return_of_the_rtmfpcat.as b/return_of_the_rtmfpcat.as index 00bba3a..f1842e4 100644 --- a/return_of_the_rtmfpcat.as +++ b/return_of_the_rtmfpcat.as @@ -215,6 +215,8 @@ package
private function poll_for_id():void { + puts("Facilitator: got " + rcp_pairs + " connections... polling for another"); + var s_f:Socket = new Socket(); s_f.addEventListener(Event.CONNECT, function (e:Event):void { puts("Facilitator: connected to " + fac_addr.host + ":" + fac_addr.port + "."); @@ -239,7 +241,8 @@ package /* Need to clear any outstanding timers to ensure * that only one timer ever runs. */ clearTimeout(fac_poll_timeo_id); - fac_poll_timeo_id = setTimeout(poll_for_id, FACILITATOR_POLL_INTERVAL); + if(rcp_pairs < MAXIMUM_RCP_PAIRS) + fac_poll_timeo_id = setTimeout(poll_for_id, FACILITATOR_POLL_INTERVAL); } }); s_f.addEventListener(SecurityErrorEvent.SECURITY_ERROR, function (e:SecurityErrorEvent):void {