Fixing another cppcheck issue.
This commit is contained in:
@@ -3840,7 +3840,8 @@ void gameTableImpl::leaveCurrentNetworkGame()
|
|||||||
void gameTableImpl::triggerVoteOnKick(int id)
|
void gameTableImpl::triggerVoteOnKick(int id)
|
||||||
{
|
{
|
||||||
|
|
||||||
assert(myStartWindow->getSession()->getCurrentGame());
|
if (myStartWindow->getSession()->getCurrentGame())
|
||||||
|
{
|
||||||
PlayerList seatList = myStartWindow->getSession()->getCurrentGame()->getSeatsList();
|
PlayerList seatList = myStartWindow->getSession()->getCurrentGame()->getSeatsList();
|
||||||
int playerCount = static_cast<int>(seatList->size());
|
int playerCount = static_cast<int>(seatList->size());
|
||||||
if (id < playerCount) {
|
if (id < playerCount) {
|
||||||
@@ -3848,6 +3849,7 @@ void gameTableImpl::triggerVoteOnKick(int id)
|
|||||||
advance(pos, id);
|
advance(pos, id);
|
||||||
myStartWindow->getSession()->startVoteKickPlayer((*pos)->getMyUniqueID());
|
myStartWindow->getSession()->startVoteKickPlayer((*pos)->getMyUniqueID());
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void gameTableImpl::startVoteOnKick(unsigned playerId, unsigned voteStarterPlayerId, int timeoutSec, int numVotesNeededToKick)
|
void gameTableImpl::startVoteOnKick(unsigned playerId, unsigned voteStarterPlayerId, int timeoutSec, int numVotesNeededToKick)
|
||||||
|
|||||||
Reference in New Issue
Block a user