sending proper signal to the bus when detecting a dead peer

This commit is contained in:
Martin Willi
2007-02-01 15:23:31 +00:00
parent 280f5aeb47
commit 42dcd01ffe
+17
View File
@@ -498,6 +498,23 @@ static void dpd_detected(private_ike_sa_t *this)
}
child_sa->destroy(child_sa);
}
/* send a proper signal to brief interested bus listeners */
switch (this->state)
{
case IKE_CONNECTING:
SIG(IKE_UP_FAILED, "establishing IKE_SA failed, peer not responding");
break;
case IKE_REKEYING:
SIG(IKE_REKEY_FAILED, "rekeying IKE_SA failed, peer not responding");
break;
case IKE_DELETING:
SIG(IKE_DOWN_FAILED, "proper IKE_SA delete failed, peer not responding");
break;
default:
break;
}
DESTROY_IF(connection);
}