summaryrefslogtreecommitdiff
path: root/src/remoteplayer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/remoteplayer.cpp')
-rw-r--r--src/remoteplayer.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/remoteplayer.cpp b/src/remoteplayer.cpp
index 0a4591410..c8e5b9132 100644
--- a/src/remoteplayer.cpp
+++ b/src/remoteplayer.cpp
@@ -141,7 +141,7 @@ void RemotePlayer::deSerialize(std::istream &is, const std::string &playername,
m_dirty = true;
//args.getS32("version"); // Version field value not used
- std::string name = args.get("name");
+ const std::string &name = args.get("name");
strlcpy(m_name, name.c_str(), PLAYERNAME_SIZE);
if (sao) {
@@ -167,7 +167,7 @@ void RemotePlayer::deSerialize(std::istream &is, const std::string &playername,
} catch (SettingNotFoundException &e) {}
try {
- std::string extended_attributes = args.get("extended_attributes");
+ const std::string &extended_attributes = args.get("extended_attributes");
Json::Reader reader;
Json::Value attr_root;
reader.parse(extended_attributes, attr_root);