mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2024-12-30 10:26:58 +01:00
add const to a few formal param declarations
This commit is contained in:
parent
9aa8faa1d1
commit
cb2990b720
2 changed files with 11 additions and 11 deletions
|
@ -129,7 +129,7 @@ static AddressRecord* getRecordFor( CommsCtxt* comms,
|
||||||
XP_PlayerAddr channelNo );
|
XP_PlayerAddr channelNo );
|
||||||
static XP_S16 sendMsg( CommsCtxt* comms, MsgQueueElem* elem );
|
static XP_S16 sendMsg( CommsCtxt* comms, MsgQueueElem* elem );
|
||||||
static void addToQueue( CommsCtxt* comms, MsgQueueElem* newMsgElem );
|
static void addToQueue( CommsCtxt* comms, MsgQueueElem* newMsgElem );
|
||||||
static XP_U16 countAddrRecs( CommsCtxt* comms );
|
static XP_U16 countAddrRecs( const CommsCtxt* comms );
|
||||||
#ifdef XWFEATURE_RELAY
|
#ifdef XWFEATURE_RELAY
|
||||||
static void relayConnect( CommsCtxt* comms );
|
static void relayConnect( CommsCtxt* comms );
|
||||||
static void relayDisconnect( CommsCtxt* comms );
|
static void relayDisconnect( CommsCtxt* comms );
|
||||||
|
@ -394,7 +394,7 @@ comms_start( CommsCtxt* comms )
|
||||||
} /* comms_start */
|
} /* comms_start */
|
||||||
|
|
||||||
static void
|
static void
|
||||||
addrToStream( XWStreamCtxt* stream, CommsAddrRec* addrP )
|
addrToStream( XWStreamCtxt* stream, const CommsAddrRec* addrP )
|
||||||
{
|
{
|
||||||
CommsAddrRec addr;
|
CommsAddrRec addr;
|
||||||
XP_MEMCPY( &addr, addrP, sizeof(addr) );
|
XP_MEMCPY( &addr, addrP, sizeof(addr) );
|
||||||
|
@ -432,7 +432,7 @@ addrToStream( XWStreamCtxt* stream, CommsAddrRec* addrP )
|
||||||
} /* addrToStream */
|
} /* addrToStream */
|
||||||
|
|
||||||
void
|
void
|
||||||
comms_writeToStream( CommsCtxt* comms, XWStreamCtxt* stream )
|
comms_writeToStream( const CommsCtxt* comms, XWStreamCtxt* stream )
|
||||||
{
|
{
|
||||||
XP_U16 nAddrRecs;
|
XP_U16 nAddrRecs;
|
||||||
AddressRecord* rec;
|
AddressRecord* rec;
|
||||||
|
@ -493,7 +493,7 @@ comms_writeToStream( CommsCtxt* comms, XWStreamCtxt* stream )
|
||||||
} /* comms_writeToStream */
|
} /* comms_writeToStream */
|
||||||
|
|
||||||
void
|
void
|
||||||
comms_getAddr( CommsCtxt* comms, CommsAddrRec* addr )
|
comms_getAddr( const CommsCtxt* comms, CommsAddrRec* addr )
|
||||||
{
|
{
|
||||||
XP_ASSERT( !!comms );
|
XP_ASSERT( !!comms );
|
||||||
XP_MEMCPY( addr, &comms->addr, sizeof(*addr) );
|
XP_MEMCPY( addr, &comms->addr, sizeof(*addr) );
|
||||||
|
@ -537,13 +537,13 @@ comms_getInitialAddr( CommsAddrRec* addr )
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
CommsConnType
|
CommsConnType
|
||||||
comms_getConType( CommsCtxt* comms )
|
comms_getConType( const CommsCtxt* comms )
|
||||||
{
|
{
|
||||||
return comms->addr.conType;
|
return comms->addr.conType;
|
||||||
} /* comms_getConType */
|
} /* comms_getConType */
|
||||||
|
|
||||||
XP_Bool
|
XP_Bool
|
||||||
comms_getIsServer( CommsCtxt* comms )
|
comms_getIsServer( const CommsCtxt* comms )
|
||||||
{
|
{
|
||||||
return comms->isServer;
|
return comms->isServer;
|
||||||
}
|
}
|
||||||
|
@ -1109,7 +1109,7 @@ getRecordFor( CommsCtxt* comms, XP_PlayerAddr channelNo )
|
||||||
} /* getRecordFor */
|
} /* getRecordFor */
|
||||||
|
|
||||||
static XP_U16
|
static XP_U16
|
||||||
countAddrRecs( CommsCtxt* comms )
|
countAddrRecs( const CommsCtxt* comms )
|
||||||
{
|
{
|
||||||
short count = 0;
|
short count = 0;
|
||||||
AddressRecord* recs;
|
AddressRecord* recs;
|
||||||
|
|
|
@ -92,17 +92,17 @@ void comms_setConnID( CommsCtxt* comms, XP_U32 connID );
|
||||||
|
|
||||||
/* "static" method provides default when no comms present */
|
/* "static" method provides default when no comms present */
|
||||||
void comms_getInitialAddr( CommsAddrRec* addr );
|
void comms_getInitialAddr( CommsAddrRec* addr );
|
||||||
void comms_getAddr( CommsCtxt* comms, CommsAddrRec* addr );
|
void comms_getAddr( const CommsCtxt* comms, CommsAddrRec* addr );
|
||||||
void comms_setAddr( CommsCtxt* comms, const CommsAddrRec* addr );
|
void comms_setAddr( CommsCtxt* comms, const CommsAddrRec* addr );
|
||||||
|
|
||||||
CommsConnType comms_getConType( CommsCtxt* comms );
|
CommsConnType comms_getConType( const CommsCtxt* comms );
|
||||||
XP_Bool comms_getIsServer( CommsCtxt* comms );
|
XP_Bool comms_getIsServer( const CommsCtxt* comms );
|
||||||
|
|
||||||
CommsCtxt* comms_makeFromStream( MPFORMAL XWStreamCtxt* stream,
|
CommsCtxt* comms_makeFromStream( MPFORMAL XWStreamCtxt* stream,
|
||||||
XW_UtilCtxt* util, TransportSend sendproc,
|
XW_UtilCtxt* util, TransportSend sendproc,
|
||||||
void* closure );
|
void* closure );
|
||||||
void comms_start( CommsCtxt* comms );
|
void comms_start( CommsCtxt* comms );
|
||||||
void comms_writeToStream( CommsCtxt* comms, XWStreamCtxt* stream );
|
void comms_writeToStream( const CommsCtxt* comms, XWStreamCtxt* stream );
|
||||||
|
|
||||||
XP_S16 comms_send( CommsCtxt* comms, XWStreamCtxt* stream );
|
XP_S16 comms_send( CommsCtxt* comms, XWStreamCtxt* stream );
|
||||||
XP_S16 comms_resendAll( CommsCtxt* comms );
|
XP_S16 comms_resendAll( CommsCtxt* comms );
|
||||||
|
|
Loading…
Reference in a new issue