summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usr.sbin/ldpd/labelmapping.c7
-rw-r--r--usr.sbin/ldpd/notification.c7
2 files changed, 2 insertions, 12 deletions
diff --git a/usr.sbin/ldpd/labelmapping.c b/usr.sbin/ldpd/labelmapping.c
index fc1b998a223..1b7a1e1b645 100644
--- a/usr.sbin/ldpd/labelmapping.c
+++ b/usr.sbin/ldpd/labelmapping.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: labelmapping.c,v 1.46 2016/05/23 19:14:03 renato Exp $ */
+/* $OpenBSD: labelmapping.c,v 1.47 2016/06/11 01:44:02 renato Exp $ */
/*
* Copyright (c) 2014, 2015 Renato Westphal <renato@openbsd.org>
@@ -241,11 +241,6 @@ recv_labelmessage(struct nbr *nbr, char *buf, uint16_t len, uint16_t type)
}
memcpy(&tlv, buf, sizeof(tlv));
- if (ntohs(tlv.length) != len - TLV_HDR_LEN) {
- session_shutdown(nbr, S_BAD_TLV_LEN, lm.msgid,
- lm.type);
- goto err;
- }
buf += TLV_HDR_LEN;
len -= TLV_HDR_LEN;
diff --git a/usr.sbin/ldpd/notification.c b/usr.sbin/ldpd/notification.c
index 7e823557285..538ca41636b 100644
--- a/usr.sbin/ldpd/notification.c
+++ b/usr.sbin/ldpd/notification.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: notification.c,v 1.31 2016/06/08 22:00:12 renato Exp $ */
+/* $OpenBSD: notification.c,v 1.32 2016/06/11 01:44:02 renato Exp $ */
/*
* Copyright (c) 2009 Michele Marchetto <michele@openbsd.org>
@@ -130,11 +130,6 @@ recv_notification(struct nbr *nbr, char *buf, uint16_t len)
}
memcpy(&tlv, buf, sizeof(tlv));
- if (ntohs(tlv.length) > len - TLV_HDR_LEN) {
- session_shutdown(nbr, S_BAD_TLV_LEN, not.msgid,
- not.type);
- return (-1);
- }
buf += TLV_HDR_LEN;
len -= TLV_HDR_LEN;