diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-03-08 11:28:03 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-03-08 11:28:03 +0000 |
commit | bc1acff091e610ad7a6c7127b364fe9b6339f51a (patch) | |
tree | b1a758dc607cc0369a4df3a5978d4f12743cda5f /src/modules/m_spanningtree.cpp | |
parent | 7804a295387c003e8a8a11e97c0b6eb2915e3ff4 (diff) |
Added ConvToStr
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3546 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_spanningtree.cpp')
-rw-r--r-- | src/modules/m_spanningtree.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/modules/m_spanningtree.cpp b/src/modules/m_spanningtree.cpp index f022d48c6..c40e99b40 100644 --- a/src/modules/m_spanningtree.cpp +++ b/src/modules/m_spanningtree.cpp @@ -468,6 +468,13 @@ class Link ConfigReader *Conf; std::vector<Link> LinkBlocks; +template<typename T> inline string ConvToStr(const T &in) +{ + stringstream tmp; + if (!(tmp << in)) return string(); + return tmp.str(); +} + /* Yay for fast searches! * This is hundreds of times faster than recursion * or even scanning a linked list, especially when |