use const references where appropriate
This commit is contained in:
committed by
Jack Grigg
parent
5e478618e6
commit
db954a65ac
@@ -50,7 +50,7 @@ std::string CUnsignedAlert::ToString() const
|
||||
BOOST_FOREACH(int n, setCancel)
|
||||
strSetCancel += strprintf("%d ", n);
|
||||
std::string strSetSubVer;
|
||||
BOOST_FOREACH(std::string str, setSubVer)
|
||||
BOOST_FOREACH(const std::string& str, setSubVer)
|
||||
strSetSubVer += "\"" + str + "\" ";
|
||||
return strprintf(
|
||||
"CAlert(\n"
|
||||
@@ -112,7 +112,7 @@ bool CAlert::Cancels(const CAlert& alert) const
|
||||
return (alert.nID <= nCancel || setCancel.count(alert.nID));
|
||||
}
|
||||
|
||||
bool CAlert::AppliesTo(int nVersion, std::string strSubVerIn) const
|
||||
bool CAlert::AppliesTo(int nVersion, const std::string& strSubVerIn) const
|
||||
{
|
||||
// TODO: rework for client-version-embedded-in-strSubVer ?
|
||||
return (IsInEffect() &&
|
||||
|
||||
Reference in New Issue
Block a user