summaryrefslogtreecommitdiff
path: root/src/ipcpd/ipcp.h
diff options
context:
space:
mode:
authorSander Vrijders <[email protected]>2016-10-26 14:59:43 +0200
committerSander Vrijders <[email protected]>2016-10-26 15:10:28 +0200
commit188aba280f7c5b80b868cb1527fce9d45702a196 (patch)
tree5a0852a4832cc853d45e96f0087e7724c8b205a1 /src/ipcpd/ipcp.h
parentcc64e52dee3559128293a17a669e94acb48f9309 (diff)
downloadouroboros-188aba280f7c5b80b868cb1527fce9d45702a196.tar.gz
ouroboros-188aba280f7c5b80b868cb1527fce9d45702a196.zip
ipcpd: Add threadpool for main loop
This adds a threadpool for the main loop of the IPCPs. Before there was a single thread handling each request, which could result in starvation since performing name queries at the same time as enrolling a normal IPCP was impossible.
Diffstat (limited to 'src/ipcpd/ipcp.h')
-rw-r--r--src/ipcpd/ipcp.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/ipcpd/ipcp.h b/src/ipcpd/ipcp.h
index 18a5bdab..c89fe438 100644
--- a/src/ipcpd/ipcp.h
+++ b/src/ipcpd/ipcp.h
@@ -50,7 +50,9 @@ struct ipcp {
pthread_mutex_t state_mtx;
pthread_cond_t state_cond;
- pthread_t mainloop;
+ int sockfd;
+ char * sock_path;
+ pthread_t * threadpool;
} ipcpi;
int ipcp_init(enum ipcp_type type,