From 7125293d65d73a451ec203c8c1630c236171f5a3 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Thu, 24 Sep 2015 09:25:19 -0400 Subject: lib: zclient.c remove extern struct thread_master * zclient.c depended upon link time inclusion of a extern struct thread_master *master. This is a violation of the namespace of the calling daemon. If a library needs the pointer pass it in and save it for future use. This code change also makes the zclient code consistent with the other lib functions that need to schedule work on your behalf Signed-off-by: Donald Sharp --- ripd/rip_zebra.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'ripd/rip_zebra.c') diff --git a/ripd/rip_zebra.c b/ripd/rip_zebra.c index de981623..0b6c22a8 100644 --- a/ripd/rip_zebra.c +++ b/ripd/rip_zebra.c @@ -710,10 +710,10 @@ rip_zebra_connected (struct zclient *zclient) } void -rip_zclient_init () +rip_zclient_init (struct thread_master *master) { /* Set default value to the zebra client structure. */ - zclient = zclient_new (); + zclient = zclient_new (master); zclient_init (zclient, ZEBRA_ROUTE_RIP); zclient->zebra_connected = rip_zebra_connected; zclient->interface_add = rip_interface_add; -- cgit v1.2.3