From aa990a9f58b5f46da95eb360049577a8833d649e Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Mon, 18 Aug 2008 14:13:29 -0700 Subject: Use XCALLOC Replace calls to XMALLOC followed by memset with XCALLOC. --- ospfd/ospf_zebra.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'ospfd/ospf_zebra.c') diff --git a/ospfd/ospf_zebra.c b/ospfd/ospf_zebra.c index c627afb2..3afbcbb7 100644 --- a/ospfd/ospf_zebra.c +++ b/ospfd/ospf_zebra.c @@ -1126,10 +1126,7 @@ ospf_prefix_list_update (struct prefix_list *plist) static struct ospf_distance * ospf_distance_new (void) { - struct ospf_distance *new; - new = XMALLOC (MTYPE_OSPF_DISTANCE, sizeof (struct ospf_distance)); - memset (new, 0, sizeof (struct ospf_distance)); - return new; + return XCALLOC (MTYPE_OSPF_DISTANCE, sizeof (struct ospf_distance)); } static void -- cgit v1.2.3