mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-16 22:58:34 +00:00
Prefer prefix ++/-- on non-primitive types
Postfix ++/-- might cause the creation of a tmp instance that might be optimized out. Mights are bad. Prefix doesn't have this problem.
This commit is contained in:
+4
-4
@@ -294,7 +294,7 @@ PTimerList::~PTimerList() {
|
||||
while(s != _list.end()) {
|
||||
if(s->second != nullptr)
|
||||
delete s->second;
|
||||
s++;
|
||||
++s;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -305,7 +305,7 @@ bool PTimerList::Load(Database *db) {
|
||||
while(s != _list.end()) {
|
||||
if(s->second != nullptr)
|
||||
delete s->second;
|
||||
s++;
|
||||
++s;
|
||||
}
|
||||
_list.clear();
|
||||
|
||||
@@ -373,7 +373,7 @@ bool PTimerList::Store(Database *db) {
|
||||
if(!s->second->Store(db))
|
||||
res = false;
|
||||
}
|
||||
s++;
|
||||
++s;
|
||||
}
|
||||
return(res);
|
||||
}
|
||||
@@ -474,7 +474,7 @@ void PTimerList::ToVector(std::vector< std::pair<pTimerType, PersistentTimer *>
|
||||
p.second = s->second;
|
||||
out.push_back(p);
|
||||
}
|
||||
s++;
|
||||
++s;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user