diff --git a/bgpd/bgpd.c b/bgpd/bgpd.c index 5ed630b49d9e..c886914fc00f 100644 --- a/bgpd/bgpd.c +++ b/bgpd/bgpd.c @@ -7493,6 +7493,7 @@ bgp_master_init (void) /* Enable multiple instances by default. */ bgp_option_set (BGP_OPT_MULTIPLE_INSTANCE); + qobj_init (); QOBJ_REG (bm, bgp_master); } diff --git a/lib/qobj.c b/lib/qobj.c index aeae52e02974..8a386d24862e 100644 --- a/lib/qobj.c +++ b/lib/qobj.c @@ -73,7 +73,8 @@ void *qobj_get_typed(uint64_t id, struct qobj_nodetype *type) void qobj_init (void) { - nodes = hash_create (qobj_key, qobj_cmp); + if (!nodes) + nodes = hash_create (qobj_key, qobj_cmp); } void qobj_finish (void)