summaryrefslogtreecommitdiffstats
path: root/nhrpd
diff options
context:
space:
mode:
authorPhilippe Guibert <philippe.guibert@6wind.com>2019-07-16 15:04:33 +0200
committerPhilippe Guibert <philippe.guibert@6wind.com>2021-04-09 18:29:58 +0200
commite8263bdb776638c3837da2f34fa52a5a9f951b35 (patch)
tree47db50f58feff3d5c4449f9b26cb59804910cab0 /nhrpd
parentnhrpd: lookup appropriate ipsec path (diff)
downloadfrr-e8263bdb776638c3837da2f34fa52a5a9f951b35.tar.xz
frr-e8263bdb776638c3837da2f34fa52a5a9f951b35.zip
nhrpd: use CALLOC instead of MALLOC
in order to apply a memset to a non initialised structure, use CALLOC instead of MALLOC Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'nhrpd')
-rw-r--r--nhrpd/zbuf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/nhrpd/zbuf.c b/nhrpd/zbuf.c
index a23526af4..43ce97481 100644
--- a/nhrpd/zbuf.c
+++ b/nhrpd/zbuf.c
@@ -27,7 +27,7 @@ struct zbuf *zbuf_alloc(size_t size)
{
struct zbuf *zb;
- zb = XMALLOC(MTYPE_ZBUF_DATA, sizeof(*zb) + size);
+ zb = XCALLOC(MTYPE_ZBUF_DATA, sizeof(*zb) + size);
zbuf_init(zb, zb + 1, size, 0);
zb->allocated = 1;