signature change: return void instead of always returning true

This commit is contained in:
Eric House 2014-12-15 15:33:12 -08:00
parent 4835afbe4a
commit 92fd048eef
2 changed files with 7 additions and 10 deletions

View file

@ -680,11 +680,10 @@ CookieRef::handleEvents()
case XWA_SEND_CONNRSP:
{
HostID hid;
if ( increasePlayerCounts( &evt, false, &hid, &devID ) ) {
setAllConnectedTimer();
sendResponse( &evt, true, &devID );
setAckTimer( hid );
}
increasePlayerCounts( &evt, false, &hid, &devID );
setAllConnectedTimer();
sendResponse( &evt, true, &devID );
setAckTimer( hid );
}
break;
@ -911,7 +910,7 @@ CookieRef::send_stored_messages( HostID dest, const AddrInfo* addr )
}
} /* send_stored_messages */
bool
void
CookieRef::increasePlayerCounts( CRefEvent* evt, bool reconn, HostID* hidp,
DevIDRelay* devIDp )
{
@ -996,8 +995,6 @@ CookieRef::increasePlayerCounts( CRefEvent* evt, bool reconn, HostID* hidp,
logf( XW_LOGVERBOSE1, "%s: here=%d; total=%d", __func__,
m_nPlayersHere, m_nPlayersSought );
return true;
} /* increasePlayerCounts */
void

View file

@ -59,7 +59,7 @@ public:
m_seed = seed;
m_lastHeartbeat = uptime();
m_ackPending = ackPending;
}
}
AddrInfo m_addr;
int m_nPlayersH;
@ -236,7 +236,7 @@ class CookieRef {
const DevIDRelay* devID );
void sendAnyStored( const CRefEvent* evt );
void initPlayerCounts( const CRefEvent* evt );
bool increasePlayerCounts( CRefEvent* evt, bool reconn, HostID* hidp,
void increasePlayerCounts( CRefEvent* evt, bool reconn, HostID* hidp,
DevIDRelay* devID );
void updateAck( HostID hostID, bool keep );
void dropPending( int seed );