summaryrefslogtreecommitdiff
path: root/src/ipcpd/local/main.c
diff options
context:
space:
mode:
authorSander Vrijders <sander.vrijders@intec.ugent.be>2016-06-14 14:56:55 +0200
committerSander Vrijders <sander.vrijders@intec.ugent.be>2016-06-14 14:56:55 +0200
commit337ab9fe73b86306b72b9eaae3b7be759f7bbd36 (patch)
treed7b237631ef17df911ec4aef766aba085a63bd30 /src/ipcpd/local/main.c
parent6019a5b1ee574c8cea485ce5ba68ff77a24b4786 (diff)
parent6271d09bdd17114c3095b7e819a7bcded14f26a5 (diff)
downloadouroboros-337ab9fe73b86306b72b9eaae3b7be759f7bbd36.tar.gz
ouroboros-337ab9fe73b86306b72b9eaae3b7be759f7bbd36.zip
Merge remote-tracking branch 'upstream/be' into be-llc
Diffstat (limited to 'src/ipcpd/local/main.c')
-rw-r--r--src/ipcpd/local/main.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/ipcpd/local/main.c b/src/ipcpd/local/main.c
index 4a0ad683..6357487f 100644
--- a/src/ipcpd/local/main.c
+++ b/src/ipcpd/local/main.c
@@ -341,7 +341,6 @@ static int ipcp_local_name_unreg(char * name)
static int ipcp_local_flow_alloc(pid_t n_pid,
int port_id,
char * dst_name,
- char * src_ap_name,
char * src_ae_name,
enum qos_cube qos)
{
@@ -350,9 +349,9 @@ static int ipcp_local_flow_alloc(pid_t n_pid,
struct shm_ap_rbuff * rb;
- LOG_INFO("Allocating flow from %s to %s.", src_ap_name, dst_name);
+ LOG_INFO("Allocating flow to %s.", dst_name);
- if (dst_name == NULL || src_ap_name == NULL || src_ae_name == NULL)
+ if (dst_name == NULL || src_ae_name == NULL)
return -1;
/* This ipcpd has all QoS */
@@ -387,7 +386,6 @@ static int ipcp_local_flow_alloc(pid_t n_pid,
/* reply to IRM */
port_id = ipcp_flow_req_arr(getpid(),
dst_name,
- src_ap_name,
src_ae_name);
if (port_id < 0) {
@@ -521,7 +519,9 @@ static int ipcp_local_flow_dealloc(int port_id)
bmp_release(_ap_instance->fds, fd);
- _ap_instance->in_out[_ap_instance->in_out[fd]] = -1;
+ if (_ap_instance->in_out[fd] != -1)
+ _ap_instance->in_out[_ap_instance->in_out[fd]] = -1;
+
_ap_instance->in_out[fd] = -1;
_ap_instance->flows[fd].state = FLOW_NULL;