summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--main.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/main.cpp b/main.cpp
index aa92b64..c863cca 100644
--- a/main.cpp
+++ b/main.cpp
@@ -261,7 +261,8 @@ static void playMatch(Player &p1, Player &p2, int index, const Params &params) {
while (true) {
for (int i = 0; i < 2; i++) {
if (!procs[i].writeLine(lastMove)) {
- cout << "ERROR writing move to player " << i+1 << endl;
+ cout << "ERROR writing move to player " << i+1
+ << " (game " << gameCodeName(p1, p2, index) << ")" << endl;
throw StopCompetitionError();
}
@@ -269,7 +270,8 @@ static void playMatch(Player &p1, Player &p2, int index, const Params &params) {
int64_t start = gettimestamp();
optional<string> oline = procs[i].readLine();
if (!oline) {
- cout << "ERROR reading move from player " << i+1 << endl;
+ cout << "ERROR reading move from player " << i+1
+ << " (game " << gameCodeName(p1, p2, index) << ")" << endl;
throw StopCompetitionError();
}
@@ -287,7 +289,8 @@ static void playMatch(Player &p1, Player &p2, int index, const Params &params) {
}
if (!referee.moveValid(i, lastMove)) {
- cout << "ERROR in player " << i+1 << ": invalid move '" << lastMove << "'" << endl;
+ cout << "ERROR in player " << i+1 << ": invalid move '" << lastMove << "'"
+ << " (game " << gameCodeName(p1, p2, index) << ")" << endl;
throw StopCompetitionError();
}