X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fmove.cpp;h=74271b31428346238877a968029a488f759f8797;hb=6c9c6dd989b037992f789ea182cafb630ca77f7c;hp=7e171f7a6a9bc388d8a7fe4624dd15d9904c9609;hpb=b9bc6e823f061753419e563c4f923e60bd8c6193;p=stockfish diff --git a/src/move.cpp b/src/move.cpp index 7e171f7a..74271b31 100644 --- a/src/move.cpp +++ b/src/move.cpp @@ -56,7 +56,10 @@ const string move_to_uci(Move m, bool chess960) { /// simple coordinate notation and returns an equivalent Move if any. /// Moves are guaranteed to be legal. -Move move_from_uci(const Position& pos, const string& str) { +Move move_from_uci(const Position& pos, string& str) { + + if (str.length() == 5) // Junior could send promotion in uppercase + str[4] = char(tolower(str[4])); for (MoveList ml(pos); !ml.end(); ++ml) if (str == move_to_uci(ml.move(), pos.is_chess960()))