From: Ronald de Man Date: Sat, 10 Feb 2018 00:44:05 +0000 (+0100) Subject: Fix gcc PGO build on Windows X-Git-Url: https://git.sesse.net/?p=stockfish;a=commitdiff_plain;h=860223c5e6b2df53af0415dbbbfdd4834f083708 Fix gcc PGO build on Windows This fixes the issue #1375 of the PGO builds failing under Windows: https://github.com/official-stockfish/Stockfish/issues/1375 Solution found during this discussion in the fishcooking forum: https://groups.google.com/forum/?fromgroups=#!topic/fishcooking/RjIPgeFFLPQ Closes #1408. No functional change. --- diff --git a/src/uci.cpp b/src/uci.cpp index adba98da..b4772305 100644 --- a/src/uci.cpp +++ b/src/uci.cpp @@ -89,11 +89,11 @@ namespace { // Read option name (can contain spaces) while (is >> token && token != "value") - name += string(" ", name.empty() ? 0 : 1) + token; + name += (name.empty() ? "" : " ") + token; // Read option value (can contain spaces) while (is >> token) - value += string(" ", value.empty() ? 0 : 1) + token; + value += (value.empty() ? "" : " ") + token; if (Options.count(name)) Options[name] = value;