]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
Just comments
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Thu, 17 Aug 2006 14:23:22 +0000 (14:23 +0000)
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Thu, 17 Aug 2006 14:23:22 +0000 (14:23 +0000)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4935 e03df62e-2008-0410-955e-edbf42e46eb7

src/users.cpp

index f833efb9924bb507ef09aa9c6fb6d9069eb5a80c..261ee491eda0d5e9c8fd2a1d4e619520a561a26f 100644 (file)
@@ -477,7 +477,12 @@ bool userrec::HasPermission(const std::string &command)
        return false;
 }
 
-
+/** NOTE: We cannot pass a const reference to this method.
+ * The string is changed by the workings of the method,
+ * so that if we pass const ref, we end up copying it to
+ * something we can change anyway. Makes sense to just let
+ * the compiler do that copy for us.
+ */
 bool userrec::AddBuffer(std::string a)
 {
        std::string::size_type i = a.rfind('\r');
@@ -1269,7 +1274,12 @@ const char* userrec::GetIPString(char* buf)
        return "";
 }
 
-
+/** NOTE: We cannot pass a const reference to this method.
+ * The string is changed by the workings of the method,
+ * so that if we pass const ref, we end up copying it to
+ * something we can change anyway. Makes sense to just let
+ * the compiler do that copy for us.
+ */
 void userrec::Write(std::string text)
 {
        if ((this->fd < 0) || (this->fd > MAX_DESCRIPTORS))