summaryrefslogtreecommitdiff
path: root/IPC.h
diff options
context:
space:
mode:
Diffstat (limited to 'IPC.h')
-rw-r--r--IPC.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/IPC.h b/IPC.h
new file mode 100644
index 0000000..9e497de
--- /dev/null
+++ b/IPC.h
@@ -0,0 +1,25 @@
+#pragma once
+
+#include <sys/socket.h>
+#include <sys/un.h>
+
+#include "commands.h"
+#include "config.h"
+#include "util.h"
+
+class IPCModule
+{
+public:
+ IPCModule(CommandsModule& commandsModule, Config& cfg, Globals& globals);
+ void doListen();
+ void quitIPC();
+ int getFD();
+private:
+ CommandsModule& commandsModule;
+ Config& cfg;
+ Globals& globals;
+ int sockfd;
+ int len;
+ bool first = true;
+ sockaddr_un address;
+};