return false if no move found -- to really fix the crash

This commit is contained in:
Andy2 2010-07-07 06:40:34 -07:00
parent 5725f36db8
commit a7c77785f6

View file

@ -513,7 +513,8 @@ engine_findMove( EngineCtxt* engine, const ModelCtxt* model,
result = XP_FALSE;
} else {
PossibleMove* move;
if ( chooseMove( engine, &move ) ) {
result = chooseMove( engine, &move );
if ( result ) {
XP_ASSERT( !!newMove );
XP_MEMCPY( newMove, &move->moveInfo, sizeof(*newMove) );
}