]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
IRC: clean up on engine shutdown
authorJānis Rūcis <parasti@gmail.com>
Wed, 31 Mar 2010 00:19:51 +0000 (03:19 +0300)
committernitroxis <nitroxis@wtwrp.de>
Fri, 10 Jan 2014 19:33:32 +0000 (20:33 +0100)
Conflicts:
irc.h

host.c
irc.c
irc.h [new file with mode: 0644]

diff --git a/host.c b/host.c
index 7e7bc56a7f2950de8df0e6c6a9ffa52273338326..a7af4c0fb95b23a4375e597b88dfa25974a1d868 100644 (file)
--- a/host.c
+++ b/host.c
@@ -1440,6 +1440,7 @@ void Host_Shutdown(void)
 #endif
        S_Terminate ();
        Curl_Shutdown ();
+       IRC_Shutdown ();
        NetConn_Shutdown ();
        //PR_Shutdown ();
 
diff --git a/irc.c b/irc.c
index e9050574e080c560a452dca8ff8dd40ce0f80250..088f7ffd6a8880a9ef18cb88fca883d608b3098c 100644 (file)
--- a/irc.c
+++ b/irc.c
@@ -359,3 +359,8 @@ void IRC_Init(void)
        Cmd_AddCommand("ircdisconnect", IRC_Disconnect_f, "disconnect from an IRC server");
        Cmd_AddCommand("irc", IRC_IRC_f, "send raw messages to a connected IRC server");
 }
+
+void IRC_Shutdown(void)
+{
+       IRC_Disconnect();
+}
diff --git a/irc.h b/irc.h
new file mode 100644 (file)
index 0000000..98f9262
--- /dev/null
+++ b/irc.h
@@ -0,0 +1,8 @@
+#ifndef IRC_H
+#define IRC_H
+
+void IRC_Init(void);
+void IRC_Frame(void);
+void IRC_Shutdown(void);
+
+#endif