summaryrefslogtreecommitdiff
path: root/IPC.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'IPC.cpp')
-rw-r--r--IPC.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/IPC.cpp b/IPC.cpp
index 215a15c..0aed97e 100644
--- a/IPC.cpp
+++ b/IPC.cpp
@@ -1,6 +1,8 @@
#include "IPC.h"
+#include "ewmh.h"
#include <cstring>
+#include <string>
#include <sys/socket.h>
#include <iostream>
#include <unistd.h>
@@ -22,11 +24,16 @@ IPCModule::IPCModule(CommandsModule& commandsModule, Config& cfg, Globals& globa
if(bind(sockfd, (sockaddr*)&address, len) == -1)
{
- cout << "ERROR" << endl;
+ cout << "ERROR " << errno << endl;
}
cout << "SOCKETED" << endl;
}
+void IPCModule::init()
+{
+ setIPCPath((unsigned char*)path, strlen(path));
+}
+
void IPCModule::doListen()
{
if(listen(sockfd, 1) != 0)
@@ -69,7 +76,6 @@ void IPCModule::doListen()
void IPCModule::quitIPC()
{
close(sockfd);
- cout << path << endl;
}
int IPCModule::getFD()