summaryrefslogtreecommitdiff
path: root/usr.sbin/mrouted
diff options
context:
space:
mode:
authorKenneth R Westerback <krw@cvs.openbsd.org>2016-12-25 16:40:07 +0000
committerKenneth R Westerback <krw@cvs.openbsd.org>2016-12-25 16:40:07 +0000
commit4d7ee92b6b09fb9aa7f3e6131f28f10991844f22 (patch)
treeeada6b7b8cb474b224be48d1a8a4b800b3393a2f /usr.sbin/mrouted
parent5ceb7d5c067f6a10d018b2cb579f13da91da653e (diff)
Add some {}'s to eliminate "ambiguous else" warnings from gcc.
ok tb@ millert@
Diffstat (limited to 'usr.sbin/mrouted')
-rw-r--r--usr.sbin/mrouted/prune.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/usr.sbin/mrouted/prune.c b/usr.sbin/mrouted/prune.c
index 7e8bebad614..f250d22aca8 100644
--- a/usr.sbin/mrouted/prune.c
+++ b/usr.sbin/mrouted/prune.c
@@ -1510,11 +1510,12 @@ age_table_entry(void)
if (gt->gt_pruntbl != NULL || gt->gt_srctbl != NULL ||
gt->gt_prsent_timer > 0) {
gt->gt_timer = CACHE_LIFETIME(cache_lifetime);
- if (gt->gt_prsent_timer == -1)
+ if (gt->gt_prsent_timer == -1) {
if (gt->gt_grpmems == 0)
send_prune(gt);
else
gt->gt_prsent_timer = 0;
+ }
gtnptr = &gt->gt_gnext;
continue;
}
@@ -1547,11 +1548,12 @@ age_table_entry(void)
#endif /* RSRR */
free((char *)gt);
} else {
- if (gt->gt_prsent_timer == -1)
+ if (gt->gt_prsent_timer == -1) {
if (gt->gt_grpmems == 0)
send_prune(gt);
else
gt->gt_prsent_timer = 0;
+ }
gtnptr = &gt->gt_gnext;
}
}
@@ -1929,12 +1931,13 @@ accept_mtrace(u_int32_t src, u_int32_t dst, u_int32_t group,
resp->tr_rflags = TR_SCOPED;
else if (gt->gt_prsent_timer)
resp->tr_rflags = TR_PRUNED;
- else if (!VIFM_ISSET(vifi, gt->gt_grpmems))
+ else if (!VIFM_ISSET(vifi, gt->gt_grpmems)) {
if (VIFM_ISSET(vifi, rt->rt_children) &&
!VIFM_ISSET(vifi, rt->rt_leaves))
resp->tr_rflags = TR_OPRUNED;
else
resp->tr_rflags = TR_NO_FWD;
+ }
} else {
if (scoped_addr(vifi, group))
resp->tr_rflags = TR_SCOPED;