The test whether the second engine supports the selected variant took place
before the second engine was loaded, thus always coming to the conclusion
that the variant was not supported, and aborting the TwoMachines command.
The test is now moved to after second-engine loading (but before its
initialization, where non-supporting would become a fatal error).
if (appData.noChessProgram) return;
- if(second.protocolVersion >= 2 && !strstr(second.variants, VariantName(gameInfo.variant))) {
- DisplayError("second engine does not play this", 0);
- return;
- }
-
switch (gameMode) {
case TwoMachinesPlay:
return;
ScheduleDelayedEvent(TwoMachinesEventIfReady, 10);
return;
}
+
+ if(second.protocolVersion >= 2 && !strstr(second.variants, VariantName(gameInfo.variant))) {
+ DisplayError("second engine does not play this", 0);
+ return;
+ }
+
if(!stalling) {
InitChessProgram(&second, FALSE); // unbalances ping of second engine
SendToProgram("force\n", &second);