]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
Fixed blank crap on end of lines
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Mon, 19 Dec 2005 15:03:21 +0000 (15:03 +0000)
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Mon, 19 Dec 2005 15:03:21 +0000 (15:03 +0000)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2572 e03df62e-2008-0410-955e-edbf42e46eb7

src/modules/m_spanningtree.cpp

index 9a5b13734d94bb637429fc6c1746fb62f112ec58..b7ef6d42d7f39e32e7c8dbfa015899f21797a957 100644 (file)
@@ -1169,6 +1169,8 @@ class TreeSocket : public InspSocket
                                        int nbytes = from64tobits(out, ret.c_str(), 1024);
                                        log(DEBUG,"m_spanningtree: decrypt %d bytes",nbytes);
                                        ctx->Decrypt(out, result, nbytes, 0);
+                                       for (int t = 0; t < nbytes; t++)
+                                               if (result[t] == '\7') result[t] = 0;
                                        ret = result;
                                }
                                if (!this->ProcessLine(ret))
@@ -1193,7 +1195,7 @@ class TreeSocket : public InspSocket
                                while (line.length() % this->keylength != 0)
                                {
                                        // pad it to be a multiple of the key length
-                                       line = line + "\n";
+                                       line = line + "\7";
                                }
                        }
                        ctx->Encrypt(line.c_str(), result, line.length(),0);