diff options
author | 2010-04-15 14:55:12 +0000 | |
---|---|---|
committer | 2010-04-15 14:55:12 +0000 | |
commit | 65125de0192fc54c440b0d36db5a85dbeac9915d (patch) | |
tree | bdfcb1277ee75fd944e45d97889574447f9935e0 | |
parent | Even though label withdraw, release, and abort requests are not fully (diff) | |
download | wireguard-openbsd-65125de0192fc54c440b0d36db5a85dbeac9915d.tar.xz wireguard-openbsd-65125de0192fc54c440b0d36db5a85dbeac9915d.zip |
struct ldp_hdr has probably the worst possible layout (ending with a single
u_int16_t) and must therefor be __packed or sizeof() returns a to large size
and causes some very nasty issues.
"embrace __packed" dlg@ OK michele@
While there add new notification status types defined in RFC5036
-rw-r--r-- | usr.sbin/ldpd/ldp.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.sbin/ldpd/ldp.h b/usr.sbin/ldpd/ldp.h index bc85ae7b836..4f4a0e51b22 100644 --- a/usr.sbin/ldpd/ldp.h +++ b/usr.sbin/ldpd/ldp.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ldp.h,v 1.3 2010/02/25 17:40:46 claudio Exp $ */ +/* $OpenBSD: ldp.h,v 1.4 2010/04/15 14:55:12 claudio Exp $ */ /* * Copyright (c) 2009 Michele Marchetto <michele@openbsd.org> @@ -91,7 +91,7 @@ struct ldp_hdr { u_int16_t length; u_int32_t lsr_id; u_int16_t lspace_id; -}; +} __packed; #define LDP_HDR_SIZE 10 #define INFINITE_HOLDTIME 0xffff @@ -146,6 +146,8 @@ struct hello_prms_tlv { #define S_LAB_REQ_ABRT 0x00000015 #define S_MISS_MSG 0x00000016 #define S_UNSUP_ADDR 0x00000017 +#define S_KEEPALIVE_BAD 0x80000018 +#define S_INTERN_ERR 0x80000019 struct sess_prms_tlv { u_int16_t type; |