]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
m_spanningtree Add class SpanningTree::RemoteUser
authorAttila Molnar <attilamolnar@hush.com>
Tue, 29 Mar 2016 14:23:39 +0000 (16:23 +0200)
committerAttila Molnar <attilamolnar@hush.com>
Tue, 29 Mar 2016 14:23:39 +0000 (16:23 +0200)
src/modules/m_spanningtree/remoteuser.cpp [new file with mode: 0644]
src/modules/m_spanningtree/remoteuser.h [new file with mode: 0644]
src/modules/m_spanningtree/uid.cpp

diff --git a/src/modules/m_spanningtree/remoteuser.cpp b/src/modules/m_spanningtree/remoteuser.cpp
new file mode 100644 (file)
index 0000000..cbd1b80
--- /dev/null
@@ -0,0 +1,28 @@
+/*
+ * InspIRCd -- Internet Relay Chat Daemon
+ *
+ *   Copyright (C) 2016 Attila Molnar <attilamolnar@hush.com>
+ *
+ * This file is part of InspIRCd.  InspIRCd is free software: you can
+ * redistribute it and/or modify it under the terms of the GNU General Public
+ * License as published by the Free Software Foundation, version 2.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program.  If not, see <http://www.gnu.org/licenses/>.
+ */
+
+
+#include "inspircd.h"
+
+#include "main.h"
+#include "remoteuser.h"
+
+SpanningTree::RemoteUser::RemoteUser(const std::string& uid, Server* srv)
+       : ::RemoteUser(uid, srv)
+{
+}
diff --git a/src/modules/m_spanningtree/remoteuser.h b/src/modules/m_spanningtree/remoteuser.h
new file mode 100644 (file)
index 0000000..235cbfd
--- /dev/null
@@ -0,0 +1,31 @@
+/*
+ * InspIRCd -- Internet Relay Chat Daemon
+ *
+ *   Copyright (C) 2016 Attila Molnar <attilamolnar@hush.com>
+ *
+ * This file is part of InspIRCd.  InspIRCd is free software: you can
+ * redistribute it and/or modify it under the terms of the GNU General Public
+ * License as published by the Free Software Foundation, version 2.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program.  If not, see <http://www.gnu.org/licenses/>.
+ */
+
+
+#pragma once
+
+namespace SpanningTree
+{
+       class RemoteUser;
+}
+
+class SpanningTree::RemoteUser : public ::RemoteUser
+{
+ public:
+       RemoteUser(const std::string& uid, Server* srv);
+};
index 01465670a4c1efc6b22ab175f9e8dc18ac3eb9d3..eff5371199110a59d14f4ebd398506b38c5b14b1 100644 (file)
@@ -24,6 +24,7 @@
 
 #include "utils.h"
 #include "treeserver.h"
+#include "remoteuser.h"
 
 CmdResult CommandUID::HandleServer(TreeServer* remoteserver, std::vector<std::string>& params)
 {
@@ -73,7 +74,7 @@ CmdResult CommandUID::HandleServer(TreeServer* remoteserver, std::vector<std::st
        /* For remote users, we pass the UUID they sent to the constructor.
         * If the UUID already exists User::User() throws an exception which causes this connection to be closed.
         */
-       RemoteUser* _new = new RemoteUser(params[0], remoteserver);
+       RemoteUser* _new = new SpanningTree::RemoteUser(params[0], remoteserver);
        ServerInstance->Users->clientlist[params[2]] = _new;
        _new->nick = params[2];
        _new->host = params[3];