summaryrefslogtreecommitdiff
path: root/src/vehicle.cpp
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2010-06-05 12:16:12 +0000
committerfrosch <frosch@openttd.org>2010-06-05 12:16:12 +0000
commit1d3adb2b66989630b2a3c201ac1210a886d41a51 (patch)
treec7c2c22646cfdeb1312455bfd9d59674b7ff96be /src/vehicle.cpp
parent406c2a986571ce594f491c0fde225b89f14ac8c3 (diff)
downloadopenttd-1d3adb2b66989630b2a3c201ac1210a886d41a51.tar.xz
(svn r19931) -Fix (r19914): Convert assertion in Backup<> destructor into DEBUG() output. It was triggered on exceptions, especially when aborting world generation.
Diffstat (limited to 'src/vehicle.cpp')
-rw-r--r--src/vehicle.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/vehicle.cpp b/src/vehicle.cpp
index 30bd2f74b..7e97c465f 100644
--- a/src/vehicle.cpp
+++ b/src/vehicle.cpp
@@ -773,7 +773,7 @@ void CallVehicleTicks()
}
}
- Backup<CompanyByte> cur_company(_current_company);
+ Backup<CompanyByte> cur_company(_current_company, FILE_LINE);
for (AutoreplaceMap::iterator it = _vehicles_to_autoreplace.Begin(); it != _vehicles_to_autoreplace.End(); it++) {
v = it->first;
/* Autoreplace needs the current company set as the vehicle owner */
@@ -1112,7 +1112,7 @@ void VehicleEnterDepot(Vehicle *v)
}
if (t.IsRefit()) {
- Backup<CompanyByte> cur_company(_current_company, v->owner);
+ Backup<CompanyByte> cur_company(_current_company, v->owner, FILE_LINE);
CommandCost cost = DoCommand(v->tile, v->index, t.GetRefitCargo() | t.GetRefitSubtype() << 8, DC_EXEC, GetCmdRefitVeh(v));
cur_company.Restore();