summaryrefslogtreecommitdiff
path: root/usr.sbin/bgpd/session.c
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2010-10-15 07:45:33 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2010-10-15 07:45:33 +0000
commit41139815903eb7adfca707f5fdb591404e9ed71e (patch)
tree730877dd6f386c53be5094d6ff1d4a7b55f1ecea /usr.sbin/bgpd/session.c
parent0ea88f09f4e1ba3b8f4a9e389cc475b90c9ea2db (diff)
Add the FSM suberrors specified in draft-ietf-idr-fsm-subcode. This
should help identifying FSM errors since the state is know known. OK henning@ sthen@
Diffstat (limited to 'usr.sbin/bgpd/session.c')
-rw-r--r--usr.sbin/bgpd/session.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/usr.sbin/bgpd/session.c b/usr.sbin/bgpd/session.c
index 55b232fc8f3..7274c7de2e8 100644
--- a/usr.sbin/bgpd/session.c
+++ b/usr.sbin/bgpd/session.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: session.c,v 1.311 2010/09/02 14:03:21 sobrado Exp $ */
+/* $OpenBSD: session.c,v 1.312 2010/10/15 07:45:32 claudio Exp $ */
/*
* Copyright (c) 2003, 2004, 2005 Henning Brauer <henning@openbsd.org>
@@ -753,7 +753,8 @@ bgp_fsm(struct peer *peer, enum session_events event)
change_state(peer, STATE_IDLE, event);
break;
default:
- session_notification(peer, ERR_FSM, 0, NULL, 0);
+ session_notification(peer,
+ ERR_FSM, ERR_FSM_UNEX_OPENSENT, NULL, 0);
change_state(peer, STATE_IDLE, event);
break;
}
@@ -787,7 +788,8 @@ bgp_fsm(struct peer *peer, enum session_events event)
change_state(peer, STATE_IDLE, event);
break;
default:
- session_notification(peer, ERR_FSM, 0, NULL, 0);
+ session_notification(peer,
+ ERR_FSM, ERR_FSM_UNEX_OPENCONFIRM, NULL, 0);
change_state(peer, STATE_IDLE, event);
break;
}
@@ -827,7 +829,8 @@ bgp_fsm(struct peer *peer, enum session_events event)
change_state(peer, STATE_IDLE, event);
break;
default:
- session_notification(peer, ERR_FSM, 0, NULL, 0);
+ session_notification(peer,
+ ERR_FSM, ERR_FSM_UNEX_ESTABLISHED, NULL, 0);
change_state(peer, STATE_IDLE, event);
break;
}