Fixed edge case where the table and game go out of sync if the user manages to leave a table after the game starts... probably not too hard on a busy server or slow connection. This was the cause of 547 "WARN TableManager: No body to table mapping to clear?" lines in yesterday's log
git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@780 c613c5cb-e716-0410-b11b-feb51c14d237
This commit is contained in:
@@ -245,6 +245,11 @@ public class TableManager
|
||||
throw new InvocationException(NO_SUCH_TABLE);
|
||||
}
|
||||
|
||||
// if the table is in play, the user is not allowed to leave (he must leave the game)
|
||||
if (table.inPlay()) {
|
||||
throw new InvocationException(GAME_ALREADY_STARTED);
|
||||
}
|
||||
|
||||
// request that the user be removed from the table
|
||||
if (!table.clearPlayer(leaver.getVisibleName())) {
|
||||
throw new InvocationException(NOT_AT_TABLE);
|
||||
|
||||
Reference in New Issue
Block a user