summaryrefslogtreecommitdiffstats
path: root/ospfd/ospf_zebra.c
diff options
context:
space:
mode:
authorQuentin Young <qlyoung@cumulusnetworks.com>2017-05-05 23:22:25 +0200
committerQuentin Young <qlyoung@cumulusnetworks.com>2017-05-09 22:44:22 +0200
commit66e78ae64bc4659848517953b365606e3e70e878 (patch)
treeef1339e397feed2b56b8d653d41c03aa5b2bd94f /ospfd/ospf_zebra.c
parentlib: safely check & set thread pointers (diff)
downloadfrr-66e78ae64bc4659848517953b365606e3e70e878.tar.xz
frr-66e78ae64bc4659848517953b365606e3e70e878.zip
*: update thread_add_* calls
Pass pointer to pointer instead of assigning by return value. See previous commit message. To ensure that the behavior stays functionally correct, any assignments with the result of a thread_add* function have been transformed to set the pointer to null before passing it. These can be removed wherever the pointer is known to already be null. Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
Diffstat (limited to 'ospfd/ospf_zebra.c')
-rw-r--r--ospfd/ospf_zebra.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ospfd/ospf_zebra.c b/ospfd/ospf_zebra.c
index 314c9e72b..c22793a09 100644
--- a/ospfd/ospf_zebra.c
+++ b/ospfd/ospf_zebra.c
@@ -1278,9 +1278,9 @@ ospf_distribute_list_update (struct ospf *ospf, uintptr_t type,
return;
/* Set timer. */
- ospf->t_distribute_update =
- thread_add_timer_msec(master, ospf_distribute_list_update_timer,
- (void *)type, ospf->min_ls_interval, NULL);
+ ospf->t_distribute_update = NULL;
+ thread_add_timer_msec(master, ospf_distribute_list_update_timer, (void *)type, ospf->min_ls_interval,
+ &ospf->t_distribute_update);
}
/* If access-list is updated, apply some check. */