summaryrefslogtreecommitdiff
path: root/src/irmd/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/irmd/main.c')
-rw-r--r--src/irmd/main.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/irmd/main.c b/src/irmd/main.c
index f1993960..4ee6399d 100644
--- a/src/irmd/main.c
+++ b/src/irmd/main.c
@@ -1076,6 +1076,8 @@ static int flow_dealloc(int port_id)
rw_lock_rdlock(&instance->state_lock);
rw_lock_wrlock(&instance->flows_lock);
+ bmp_release(instance->port_ids, port_id);
+
e = get_port_map_entry(port_id);
if (e == NULL) {
rw_lock_unlock(&instance->flows_lock);
@@ -1087,8 +1089,6 @@ static int flow_dealloc(int port_id)
list_del(&e->next);
- bmp_release(instance->port_ids, port_id);
-
ret = ipcp_flow_dealloc(n_1_pid, port_id);
rw_lock_unlock(&instance->flows_lock);
@@ -1217,8 +1217,6 @@ static int flow_dealloc_ipcp(int port_id)
return 0;
}
- bmp_release(instance->port_ids, port_id);
-
list_del(&e->next);
rw_lock_unlock(&instance->flows_lock);