From ec1ca63c188c9dc2518b0f78033e623105ac4f25 Mon Sep 17 00:00:00 2001 From: paul Date: Wed, 4 Jun 2003 02:23:15 +0000 Subject: From: kamatchi soundaram Subject: [zebra 19262] Re: Memory leak in OSPF Fix applied for Kamatchi's original report was to remove the auth_crypt initialisation from the wrong function. This should fix that. --- ospfd/ospf_interface.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'ospfd') diff --git a/ospfd/ospf_interface.c b/ospfd/ospf_interface.c index 9f566a45..83abf553 100644 --- a/ospfd/ospf_interface.c +++ b/ospfd/ospf_interface.c @@ -489,6 +489,8 @@ ospf_new_if_params () UNSET_IF_PARAM (oip, auth_simple); UNSET_IF_PARAM (oip, auth_crypt); UNSET_IF_PARAM (oip, auth_type); + + oip->auth_crypt = list_new (); return oip; } @@ -623,9 +625,6 @@ ospf_if_new_hook (struct interface *ifp) SET_IF_PARAM (IF_DEF_PARAMS (ifp), auth_simple); memset (IF_DEF_PARAMS (ifp)->auth_simple, 0, OSPF_AUTH_SIMPLE_SIZE); - SET_IF_PARAM (IF_DEF_PARAMS (ifp), auth_crypt); - IF_DEF_PARAMS (ifp)->auth_crypt = list_new (); - SET_IF_PARAM (IF_DEF_PARAMS (ifp), auth_type); IF_DEF_PARAMS (ifp)->auth_type = OSPF_AUTH_NOTSET; -- cgit v1.2.1