summaryrefslogtreecommitdiff
path: root/src/irmd
diff options
context:
space:
mode:
Diffstat (limited to 'src/irmd')
-rw-r--r--src/irmd/ipcp.c13
-rw-r--r--src/irmd/main.c14
2 files changed, 13 insertions, 14 deletions
diff --git a/src/irmd/ipcp.c b/src/irmd/ipcp.c
index f79e6caf..33f7650a 100644
--- a/src/irmd/ipcp.c
+++ b/src/irmd/ipcp.c
@@ -111,6 +111,7 @@ pid_t ipcp_create(enum ipcp_type ipcp_type)
char * full_name = NULL;
char * exec_name = NULL;
char * log_file = NULL;
+ char * argv[4];
sprintf(irmd_api, "%u", getpid());
@@ -161,14 +162,12 @@ pid_t ipcp_create(enum ipcp_type ipcp_type)
}
/* log_file to be placed at the end */
- char * argv[] = {full_name,
- irmd_api,
- log_file,
- 0};
+ argv[0] = full_name;
+ argv[1] = irmd_api;
+ argv[2] = log_file;
+ argv[3] = NULL;
- char * envp[] = {0};
-
- execve(argv[0], &argv[0], envp);
+ execv(argv[0], &argv[0]);
LOG_DBG("%s", strerror(errno));
LOG_ERR("Failed to load IPCP daemon");
diff --git a/src/irmd/main.c b/src/irmd/main.c
index 157fd8eb..67941e41 100644
--- a/src/irmd/main.c
+++ b/src/irmd/main.c
@@ -28,7 +28,7 @@
#include <ouroboros/utils.h>
#include <ouroboros/irm_config.h>
#include <ouroboros/lockfile.h>
-#include <ouroboros/shm_ap_rbuff.h>
+#include <ouroboros/shm_rbuff.h>
#include <ouroboros/shm_rdrbuff.h>
#include <ouroboros/bitmap.h>
#include <ouroboros/qos.h>
@@ -1692,26 +1692,26 @@ void * irm_sanitize()
}
if (kill(f->n_api, 0) < 0) {
- struct shm_ap_rbuff * rb =
- shm_ap_rbuff_open(f->n_api);
+ struct shm_rbuff * rb =
+ shm_rbuff_open(f->n_api, f->port_id);
bmp_release(irmd->port_ids, f->port_id);
list_del(&f->next);
LOG_INFO("AP-I %d gone, flow %d deallocated.",
f->n_api, f->port_id);
ipcp_flow_dealloc(f->n_1_api, f->port_id);
if (rb != NULL)
- shm_ap_rbuff_destroy(rb);
+ shm_rbuff_destroy(rb);
irm_flow_destroy(f);
continue;
}
if (kill(f->n_1_api, 0) < 0) {
- struct shm_ap_rbuff * rb =
- shm_ap_rbuff_open(f->n_1_api);
+ struct shm_rbuff * rb =
+ shm_rbuff_open(f->n_1_api, f->port_id);
list_del(&f->next);
LOG_ERR("IPCP %d gone, flow %d removed.",
f->n_1_api, f->port_id);
if (rb != NULL)
- shm_ap_rbuff_destroy(rb);
+ shm_rbuff_destroy(rb);
irm_flow_destroy(f);
}
}