From da95a7a7dad6ebf572adfb448dfc1a5c8400e6ab Mon Sep 17 00:00:00 2001 From: Ondrej Zajicek Date: Tue, 23 Jun 2009 11:00:38 +0200 Subject: Fixes bug in ORIGIN check. --- proto/bgp/attrs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'proto') diff --git a/proto/bgp/attrs.c b/proto/bgp/attrs.c index e50f6a9c..68f21b97 100644 --- a/proto/bgp/attrs.c +++ b/proto/bgp/attrs.c @@ -39,9 +39,9 @@ struct attr_desc { }; static int -bgp_check_origin(struct bgp_proto *p UNUSED, byte *a UNUSED, int len) +bgp_check_origin(struct bgp_proto *p UNUSED, byte *a, int len UNUSED) { - if (len > 2) + if (*a > 2) return 6; return 0; } -- cgit v1.2.3