Dispatch our client tick on the RunQueue so that it doesn't end up running on a
separate thread and racing against other client actions. Also nixed a pointless type check and cast. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4828 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -386,7 +386,7 @@ public class Client
|
||||
// register an interval that we'll use to keep the clock synced and to send pings when
|
||||
// appropriate
|
||||
if (_tickInterval == null) {
|
||||
_tickInterval = new Interval() {
|
||||
_tickInterval = new Interval(_runQueue) {
|
||||
public void expired () {
|
||||
tick();
|
||||
}
|
||||
@@ -725,9 +725,7 @@ public class Client
|
||||
break;
|
||||
|
||||
case CLIENT_OBJECT_CHANGED:
|
||||
if (obs instanceof SessionObserver) {
|
||||
((SessionObserver)obs).clientObjectDidChange(Client.this);
|
||||
}
|
||||
obs.clientObjectDidChange(Client.this);
|
||||
break;
|
||||
|
||||
case CLIENT_CONNECTION_FAILED:
|
||||
|
||||
Reference in New Issue
Block a user