diff options
| author | Renato Westphal <renato@opensourcerouting.org> | 2017-03-03 17:50:22 -0300 | 
|---|---|---|
| committer | Renato Westphal <renato@opensourcerouting.org> | 2017-03-03 17:50:22 -0300 | 
| commit | 8819fc38a0610e5828b7cc65fbbfc42e6ea1cc6a (patch) | |
| tree | 190443908132c32a0e3940410884360307eefc59 /ldpd/packet.c | |
| parent | 0bcc2916a08dfb762d8a5775e6b01a4885c8936a (diff) | |
ldpd: implement RFC 5561 (LDP Capabilities)
This patch per-se doesn't introduce any useful functionality, but prepares
the ground for new enhancements to ldpd (i.e. implementation of new RFCs
that make use of LDP capabilities).
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Diffstat (limited to 'ldpd/packet.c')
| -rw-r--r-- | ldpd/packet.c | 13 | 
1 files changed, 4 insertions, 9 deletions
diff --git a/ldpd/packet.c b/ldpd/packet.c index 653f67b8c2..a7be0f6b42 100644 --- a/ldpd/packet.c +++ b/ldpd/packet.c @@ -519,13 +519,7 @@ session_read(struct thread *thread)  					return (0);  				}  				break; -			case MSG_TYPE_ADDR: -			case MSG_TYPE_ADDRWITHDRAW: -			case MSG_TYPE_LABELMAPPING: -			case MSG_TYPE_LABELREQUEST: -			case MSG_TYPE_LABELWITHDRAW: -			case MSG_TYPE_LABELRELEASE: -			case MSG_TYPE_LABELABORTREQ: +			default:  				if (nbr->state != NBR_STA_OPER) {  					session_shutdown(nbr, S_SHUTDOWN,  					    msg->id, msg->type); @@ -533,8 +527,6 @@ session_read(struct thread *thread)  					return (0);  				}  				break; -			default: -				break;  			}  			/* switch LDP packet type */ @@ -548,6 +540,9 @@ session_read(struct thread *thread)  			case MSG_TYPE_KEEPALIVE:  				ret = recv_keepalive(nbr, pdu, msg_size);  				break; +			case MSG_TYPE_CAPABILITY: +				ret = recv_capability(nbr, pdu, msg_size); +				break;  			case MSG_TYPE_ADDR:  			case MSG_TYPE_ADDRWITHDRAW:  				ret = recv_address(nbr, pdu, msg_size);  | 
