summaryrefslogtreecommitdiff
path: root/src/command.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/command.cpp')
-rw-r--r--src/command.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/command.cpp b/src/command.cpp
index f44395662..8782763e0 100644
--- a/src/command.cpp
+++ b/src/command.cpp
@@ -613,7 +613,7 @@ bool DoCommandP(TileIndex tile, uint32 p1, uint32 p2, uint32 cmd, CommandCallbac
assert(res.GetCost() == res2.GetCost() && CmdFailed(res) == CmdFailed(res2)); // sanity check
} else {
if (CmdFailed(res2)) {
- res.SetGlobalErrorMessage();
+ res2.SetGlobalErrorMessage();
goto show_error;
}
}