fix a tautology warning in unit.cpp
This commit is contained in:
parent
301c6dfc93
commit
0dd5fe612d
1 changed files with 7 additions and 7 deletions
|
@ -3422,18 +3422,18 @@ void CleanUnits()
|
|||
std::vector<CUnit *> units(UnitManager.begin(), UnitManager.end());
|
||||
|
||||
for (std::vector<CUnit *>::iterator it = units.begin(); it != units.end(); ++it) {
|
||||
CUnit &unit = **it;
|
||||
CUnit *unit = *it;
|
||||
|
||||
if (&unit == NULL) {
|
||||
if (unit == NULL) {
|
||||
continue;
|
||||
}
|
||||
if (!unit.Destroyed) {
|
||||
if (!unit.Removed) {
|
||||
unit.Remove(NULL);
|
||||
if (!unit->Destroyed) {
|
||||
if (!unit->Removed) {
|
||||
unit->Remove(NULL);
|
||||
}
|
||||
UnitClearOrders(unit);
|
||||
UnitClearOrders(*unit);
|
||||
}
|
||||
unit.Release(true);
|
||||
unit->Release(true);
|
||||
}
|
||||
|
||||
UnitManager.Init();
|
||||
|
|
Loading…
Add table
Reference in a new issue