Fix Edit Position with engine-defined variant
authorH.G.Muller <hgm@hgm-xboard.(none)>
Fri, 26 Jan 2018 13:01:19 +0000 (14:01 +0100)
committerH.G.Muller <hgm@hgm-xboard.(none)>
Fri, 26 Jan 2018 13:01:19 +0000 (14:01 +0100)
commitd655d3bf4fcf38ba369fa700f3aa538d1ce85da0
treea196d42f629664150e4d57a6c8e16527ab34e1e4
parentd81f573a5e990af8eb8de5efdea8aa156aa97c1e
Fix Edit Position with engine-defined variant

Submitting a new position starts a new game, but the position would be
set up before the engine had the time to reply to the 'variant' command
wit a 'setup'. As a consequence WinBoard would be unaware of the correct
starting position, with as a consequence that Pawns might not be considered
virgin for their Betza 'i' moves.
 Now even late reception of a 'setup' command from the engine when
startedFromSetupPosition is true will cause initialPosition to be
initialized. The assumption is that XBoard was already switched to the
variant before, so that the 'setup' command is not needed for defining the
pieceToCharTable used to interpret the FEN that set up the position.
backend.c