mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-30 08:34:16 +01:00
fix so invitation results in a playable game (though dictionary is not
yet available to invitation recipient)
This commit is contained in:
parent
2a47c91a91
commit
f45f3bacbf
3 changed files with 8 additions and 5 deletions
xwords4/linux
|
@ -536,9 +536,11 @@ createOrLoadObjects( GtkGameGlobals* globals )
|
|||
#endif
|
||||
#ifdef XWFEATURE_SMS
|
||||
case COMMS_CONN_SMS:
|
||||
XP_STRNCPY( addr.u.sms.phone, params->connInfo.sms.phone,
|
||||
sizeof(addr.u.sms.phone) - 1 );
|
||||
addr.u.sms.port = params->connInfo.sms.port;
|
||||
/* No! Don't overwrite what may be a return address with local
|
||||
stuff */
|
||||
/* XP_STRNCPY( addr.u.sms.phone, params->connInfo.sms.phone, */
|
||||
/* sizeof(addr.u.sms.phone) - 1 ); */
|
||||
/* addr.u.sms.port = params->connInfo.sms.port; */
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
|
|
|
@ -542,8 +542,8 @@ smsInviteReceived( void* closure, const XP_UCHAR* gameName, XP_U32 gameID,
|
|||
CurGameInfo gi = {0};
|
||||
gi_copy( MPPARM(params->mpool) &gi, ¶ms->pgi );
|
||||
|
||||
gi_setNPlayers( &gi, nPlayers, nHere );
|
||||
gi.gameID = gameID;
|
||||
gi.nPlayers = nPlayers;
|
||||
gi.dictLang = dictLang;
|
||||
replaceStringIfDifferent( params->mpool, &gi.dictName, dictName );
|
||||
|
||||
|
|
|
@ -225,8 +225,9 @@ dispatch_data( LinSMS2Data* storage, XP_U16 XP_UNUSED(proto),
|
|||
{
|
||||
XP_USE( addr );
|
||||
XP_U32 gameID = stream_getU32( stream );
|
||||
const XP_U8* data = stream_getPtr( stream );
|
||||
XP_U16 len = stream_getSize( stream );
|
||||
XP_U8 data[len];
|
||||
stream_getBytes( stream, data, len );
|
||||
|
||||
(*storage->procs->msgReceived)( storage->procClosure, gameID,
|
||||
data, len, addr );
|
||||
|
|
Loading…
Add table
Reference in a new issue