Skip to content

Commit e6c6edb

Browse files
committed
Copy SString by reference in CStringMap::ReadString
1 parent a84ae4c commit e6c6edb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Shared/sdk/CStringMap.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class CStringMapReader : public std::map<SString, V>
1818
void ReadString(const SString& strKeyName, SString& strOutValue, const char* szDefaultValue)
1919
{
2020
V* pstrValue = MapFind(*this, strKeyName);
21-
strOutValue = pstrValue ? **pstrValue : szDefaultValue;
21+
strOutValue = pstrValue ? *pstrValue : szDefaultValue;
2222
}
2323

2424
template <typename T, typename U>

0 commit comments

Comments
 (0)