fix bug the right way this time: it's ok for a word not to be in the

current player's wordlist when the most recent move's being reported,
but not to ignore word legality altogether.
This commit is contained in:
Eric House 2012-08-15 18:11:16 -07:00
parent de9a408b15
commit de87b32bb8

View file

@ -2146,18 +2146,16 @@ typedef struct _FirstWordData {
} FirstWordData;
static XP_Bool
getFirstWord( const XP_UCHAR* word, XP_Bool isLegal,
getFirstWord( const XP_UCHAR* word, XP_Bool XP_UNUSED(isLegal),
#ifdef XWFEATURE_BOARDWORDS
const MoveInfo* XP_UNUSED(movei), XP_U16 XP_UNUSED(start),
XP_U16 XP_UNUSED(end),
#endif
void* closure )
{
if ( isLegal ) {
FirstWordData* data = (FirstWordData*)closure;
if ( '\0' == data->word[0] && '\0' != word[0] ) {
XP_STRCAT( data->word, word );
}
FirstWordData* data = (FirstWordData*)closure;
if ( '\0' == data->word[0] && '\0' != word[0] ) {
XP_STRCAT( data->word, word );
}
return XP_TRUE;
}