From a5362f24b4dd48f7203be418c6d66f6edccb8d69 Mon Sep 17 00:00:00 2001 From: Sander Vrijders Date: Tue, 19 Jun 2018 11:38:23 +0200 Subject: ipcpd: Change connection down to flow down The DT component was flagging a connection as down and passing the fd that was down. Of course the other components expect a connection instead of just a fd. Now the connection manager will listen to flow up and down events, and flag the connection up or down if needed. Signed-off-by: Sander Vrijders Signed-off-by: Dimitri Staessens --- src/ipcpd/normal/dt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/ipcpd/normal/dt.c') diff --git a/src/ipcpd/normal/dt.c b/src/ipcpd/normal/dt.c index 397169f3..b9d8934e 100644 --- a/src/ipcpd/normal/dt.c +++ b/src/ipcpd/normal/dt.c @@ -409,7 +409,7 @@ static void sdu_handler(int fd, if (ret < 0) { log_dbg("Failed to write SDU to fd %d.", ofd); if (ret == -EFLOWDOWN) - notifier_event(NOTIFY_DT_CONN_DOWN, &ofd); + notifier_event(NOTIFY_DT_FLOW_DOWN, &ofd); ipcp_sdb_release(sdb); #ifdef IPCP_FLOW_STATS pthread_mutex_lock(&dt.stat[fd].lock); @@ -781,7 +781,7 @@ int dt_write_sdu(uint64_t dst_addr, if (ret < 0) { log_dbg("Failed to write SDU to fd %d.", fd); if (ret == -EFLOWDOWN) - notifier_event(NOTIFY_DT_CONN_DOWN, &fd); + notifier_event(NOTIFY_DT_FLOW_DOWN, &fd); goto fail_write; } #ifdef IPCP_FLOW_STATS -- cgit v1.2.3