summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Lamparter <equinox@opensourcerouting.org>2013-01-23 04:20:37 +0100
committerDavid Lamparter <equinox@opensourcerouting.org>2013-02-01 17:55:04 +0100
commitaeef13b0d5b50a90f293c93eb5a34c2a099d140b (patch)
treeb2463778c9b28b78af6ef722d2ac6b32df7ade6b
parent1cb9cf062ec3ed7a3f13fb5465eb5fb917ce3329 (diff)
tests: fix missing init in bgp_mp_attr_test.c
turns out, bgp_mp_reach_parse really doesn't like getting garbage attribute input. In particular, attr->extra better be NULL or we merrily go trample random places (like our stack). Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
-rw-r--r--tests/bgp_mp_attr_test.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/bgp_mp_attr_test.c b/tests/bgp_mp_attr_test.c
index f086740f..177c1ad8 100644
--- a/tests/bgp_mp_attr_test.c
+++ b/tests/bgp_mp_attr_test.c
@@ -436,8 +436,8 @@ parse_test (struct peer *peer, struct test_segment *t, int type)
{
int ret;
int oldfailed = failed;
- struct attr attr;
- struct bgp_nlri nlri;
+ struct attr attr = { };
+ struct bgp_nlri nlri = { };
struct bgp_attr_parser_args attr_args = {
.peer = peer,
.length = t->len,