[cleanup] Convert XMALLOC/memset to XCALLOC
Simple conversion of XMALLOC/memset to XCALLOC
diff --git a/bgpd/bgp_clist.c b/bgpd/bgp_clist.c
index f75fc55..a8d8742 100644
--- a/bgpd/bgp_clist.c
+++ b/bgpd/bgp_clist.c
@@ -51,11 +51,7 @@
static struct community_entry *
community_entry_new ()
{
- struct community_entry *new;
-
- new = XMALLOC (MTYPE_COMMUNITY_LIST_ENTRY, sizeof (struct community_entry));
- memset (new, 0, sizeof (struct community_entry));
- return new;
+ return XCALLOC (MTYPE_COMMUNITY_LIST_ENTRY, sizeof (struct community_entry));
}
/* Free community list entry. */
@@ -92,11 +88,7 @@
static struct community_list *
community_list_new ()
{
- struct community_list *new;
-
- new = XMALLOC (MTYPE_COMMUNITY_LIST, sizeof (struct community_list));
- memset (new, 0, sizeof (struct community_list));
- return new;
+ return XCALLOC (MTYPE_COMMUNITY_LIST, sizeof (struct community_list));
}
/* Free community-list. */