bug-gnu-chess
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bug with GNU Chess Version 5.02


From: Simon Waters
Subject: Re: Bug with GNU Chess Version 5.02
Date: Tue, 22 May 2001 19:16:22 +0100

> Chris Woodall wrote:
> 
> This bug concerns invalid moves.
> 
> If GenMoves(1) produces a pseudo legal moves which is
> actual illegal, i.e. due to discovered check, and that
> move is the final move in the list and is subsequently
> removed by FilterIllegalMoves(1) then GNU Chess allows you
> to make the move.
> 
> The cause I believe is the sub routine IsInMoveList the
> line that reads
> 
> for (node = TreePtr[ply]; node <= TreePtr[ply + 1];
> node++)
> 
> it should read
> 
> for (node = TreePtr[ply]; node < TreePtr[ply + 1]; node++)
> 
> due to the fact that GenMoves always leaves TreePtr[ply +
> 1] pointing to the next free slot.
> 
> The following EPD file text has an example position:
> 
> 5r2/1p2b3/2p2Pkp/8/p1p5/P3R3/1P3KP1/8 w - - bm 1; id 1;

White can play fe7 - oops. Gnuchess plays RxK  and waits for
another move.

Thanks Chris,

reproduced straight away. 

Removing "=" sign fixes that. 

Quick run through a test case show the program is as strong
as ever (stronger?) afterwards.

        Simon
-- 
Simon Waters
Are you using the Internet to best effect ?
www.eighth-layer.com
Tel: +44(0)1395 232769      ICQ: 116952768
Moderated discussion of teleworking issues at
news:uk.business.telework



reply via email to

[Prev in Thread] Current Thread [Next in Thread]