From: paul Date: Tue, 3 Jun 2003 03:03:34 +0000 (+0000) Subject: From: kamatchi soundaram X-Git-Tag: frr-2.0-rc1~4012 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=852ba0e2cf9a1c6bba0988e98512a303cc9739e8;p=matthieu%2Ffrr.git From: kamatchi soundaram Subject: [zebra 19259] Memory leak in OSPF The detail of the memory leak follows: File name: ospf_interface.c Function name: ospf_if_new_hook(). Type of leak: Overwriting the already allocated memory. Problem found and description: The ospf_new_if_params() fn allocates a memory for "auth_crypt" which is overwritten, down in the fn (ospf_if_new_hook) by explicitely allocating a memory for the same "auth_crypt". Fix: remove allocation from ospf_new_if_params() --- diff --git a/ospfd/ospf_interface.c b/ospfd/ospf_interface.c index a1b10c7439..9f566a452d 100644 --- a/ospfd/ospf_interface.c +++ b/ospfd/ospf_interface.c @@ -490,8 +490,6 @@ ospf_new_if_params () UNSET_IF_PARAM (oip, auth_crypt); UNSET_IF_PARAM (oip, auth_type); - oip->auth_crypt = list_new (); - return oip; }