X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fmisc.cpp;h=0f0fca46624da7c0212b2971c72b0d8a02c2eae8;hb=7a8429d9f15a45c5a60f98c4aed798d10d511300;hp=3206a2d1950081229b0e9d3f623ba2db66dc8f81;hpb=dda0fa1a43e1096415ff8f83dd14e6322f1a8e68;p=stockfish diff --git a/src/misc.cpp b/src/misc.cpp index 3206a2d1..0f0fca46 100644 --- a/src/misc.cpp +++ b/src/misc.cpp @@ -51,17 +51,15 @@ const string engine_info(bool to_uci) { string month, day, year; stringstream s, date(__DATE__); // From compiler, format is "Sep 21 2008" + s << "Stockfish " << Version; + if (Version.empty()) { date >> month >> day >> year; - s << "Stockfish " << Tag - << setfill('0') << " " << year.substr(2) - << setw(2) << (1 + months.find(month) / 4) - << setw(2) << day; + s << Tag << setfill('0') << " " << year.substr(2) + << setw(2) << (1 + months.find(month) / 4) << setw(2) << day; } - else - s << "Stockfish " << Version; s << cpu64 << popcnt << (to_uci ? "\nid author ": " by ") << "Tord Romstad, Marco Costalba and Joona Kiiski";