summaryrefslogtreecommitdiff
path: root/src/commands.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/commands.cpp')
-rw-r--r--src/commands.cpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/commands.cpp b/src/commands.cpp
index 94781aef5..00da06cbb 100644
--- a/src/commands.cpp
+++ b/src/commands.cpp
@@ -63,6 +63,7 @@
#include "net/download.h"
#include "net/gamehandler.h"
#include "net/guildhandler.h"
+#include "net/ipc.h"
#include "net/net.h"
#include "net/uploadcharinfo.h"
#include "net/partyhandler.h"
@@ -289,6 +290,26 @@ impHandler2(help)
helpWindow->requestMoveToTop();
}
+impHandler0(ipcToggle)
+{
+ if (ipc)
+ {
+ IPC::stop();
+ if (!ipc)
+ debugChatTab->chatLog("IPC service stopped.");
+ else
+ debugChatTab->chatLog("Unable to stop IPC service.");
+ }
+ else
+ {
+ IPC::start();
+ if (ipc)
+ debugChatTab->chatLog(strprintf("IPC service available on port %d", ipc->port()));
+ else
+ debugChatTab->chatLog("Unable to start IPC service");
+ }
+}
+
impHandler2(where)
{
std::ostringstream where;