diff options
author | yexo <yexo@openttd.org> | 2011-02-18 21:46:45 +0000 |
---|---|---|
committer | yexo <yexo@openttd.org> | 2011-02-18 21:46:45 +0000 |
commit | 72e027e4d6ff168ab9f77d1001f877c55071c59c (patch) | |
tree | a53e1cc407116771687baf06afaf9d3f464e42ce /src | |
parent | ff1e0a3ed362e13b05e3e722990e55efa688e31a (diff) | |
download | openttd-72e027e4d6ff168ab9f77d1001f877c55071c59c.tar.xz |
(svn r22105) -Fix: crash when copying an orderlist to a vehicle that already had orders
Diffstat (limited to 'src')
-rw-r--r-- | src/order_cmd.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/order_cmd.cpp b/src/order_cmd.cpp index ccfb330db..d327aa252 100644 --- a/src/order_cmd.cpp +++ b/src/order_cmd.cpp @@ -1470,6 +1470,7 @@ CommandCost CmdCloneOrder(TileIndex tile, DoCommandFlag flags, uint32 p1, uint32 assert(dst->orders.list->GetFirstOrder() == NULL); assert(!dst->orders.list->IsShared()); delete dst->orders.list; + assert(OrderList::CanAllocateItem()); dst->orders.list = new OrderList(first, dst); } |