From 838bbde0426e562132d22fb11932ea413aebf928 Mon Sep 17 00:00:00 2001 From: Paul Jakma Date: Fri, 8 Jan 2010 14:05:32 +0000 Subject: bgpd: Simplify process queue init * bgp_route.c: (bgp_process_queue_init) rsclient wasn't getting all the same things initialised as the main queue. Simplify to make it more robust. --- bgpd/bgp_route.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/bgpd/bgp_route.c b/bgpd/bgp_route.c index 1cfc4511..df23dda3 100644 --- a/bgpd/bgp_route.c +++ b/bgpd/bgp_route.c @@ -1614,14 +1614,13 @@ bgp_process_queue_init (void) } bm->process_main_queue->spec.workfunc = &bgp_process_main; - bm->process_rsclient_queue->spec.workfunc = &bgp_process_rsclient; bm->process_main_queue->spec.del_item_data = &bgp_processq_del; - bm->process_rsclient_queue->spec.del_item_data - = bm->process_main_queue->spec.del_item_data; - bm->process_main_queue->spec.max_retries - = bm->process_main_queue->spec.max_retries = 0; - bm->process_rsclient_queue->spec.hold - = bm->process_main_queue->spec.hold = 50; + bm->process_main_queue->spec.max_retries = 0; + bm->process_main_queue->spec.hold = 50; + + memcpy (bm->process_rsclient_queue, bm->process_main_queue, + sizeof (struct work_queue *)); + bm->process_rsclient_queue->spec.workfunc = &bgp_process_rsclient; } void -- cgit v1.2.1