summaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree
diff options
context:
space:
mode:
authorPeter Powell <petpow@saberuk.com>2019-05-13 17:49:26 +0100
committerPeter Powell <petpow@saberuk.com>2019-05-14 00:58:52 +0100
commite55277283800bfdfef86485a6b0c7a4e7755a15b (patch)
tree5a1d2430b4ad53a7b6fec2e618d8c2ca6b2d7802 /src/modules/m_spanningtree
parent7a58d288d0fd005795a8ac6908fc91bf350174d6 (diff)
Fix an unnecessary string copy when reading the <link> tags.
Diffstat (limited to 'src/modules/m_spanningtree')
-rw-r--r--src/modules/m_spanningtree/utils.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/modules/m_spanningtree/utils.cpp b/src/modules/m_spanningtree/utils.cpp
index f78b8d4c0..a18ec854d 100644
--- a/src/modules/m_spanningtree/utils.cpp
+++ b/src/modules/m_spanningtree/utils.cpp
@@ -258,13 +258,12 @@ void SpanningTreeUtilities::ReadConfiguration()
{
ConfigTag* tag = i->second;
reference<Link> L = new Link(tag);
- std::string linkname = tag->getString("name");
- L->Name = linkname.c_str();
irc::spacesepstream sep = tag->getString("allowmask");
for (std::string s; sep.GetToken(s);)
L->AllowMasks.push_back(s);
+ L->Name = tag->getString("name");
L->IPAddr = tag->getString("ipaddr");
L->Port = tag->getUInt("port", 0);
L->SendPass = tag->getString("sendpass", tag->getString("password"));