From: H.G.Muller <hgm@hgm-xboard.(none)>
Date: Tue, 4 Mar 2014 21:04:04 +0000 (+0100)
Subject: Fix entry of deferrals
X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=e6b3635549cc41aed90a2a9d21fec56cae757b66;p=gnushogi.git

Fix entry of deferrals

XBoard suffixes deferred promotions with an = sign, but GNU Shogi's
internal move generator to which the input move is compared doesn't.
Now we strip off the promochar if it is an =.
---

diff --git a/gnushogi/commondsp.c b/gnushogi/commondsp.c
index a03d69d..48a8ef4 100644
--- a/gnushogi/commondsp.c
+++ b/gnushogi/commondsp.c
@@ -285,6 +285,7 @@ VerifyMove(char *s, VerifyMove_mode iop, unsigned short *mv)
     MoveList(opponent, 2, -1, true);
     generate_move_flags = false;
     pnt = TrPnt[2];
+    if(s[4] == '=') s[4] = '\0'; /* deferral is implied */
 
     while (pnt < TrPnt[3])
     {