summaryrefslogtreecommitdiff
path: root/proto
diff options
context:
space:
mode:
authorOndrej Zajicek (work) <santiago@crfreenet.org>2017-05-23 13:12:25 +0200
committerOndrej Zajicek (work) <santiago@crfreenet.org>2017-05-23 13:12:25 +0200
commit734e9fb8a933898cd3396786c06728bce6a754e5 (patch)
tree610ffaa2286fc604be4b2f1c30a983f0076b1da8 /proto
parentbb7aa06a48f52813a019861a0e06ce9fe4d20c4b (diff)
Minor cleanups and fixes
Diffstat (limited to 'proto')
-rw-r--r--proto/bfd/packets.c2
-rw-r--r--proto/rip/packets.c2
-rw-r--r--proto/rip/rip.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/proto/bfd/packets.c b/proto/bfd/packets.c
index 06cde4d3..b76efda6 100644
--- a/proto/bfd/packets.c
+++ b/proto/bfd/packets.c
@@ -248,7 +248,7 @@ bfd_check_authentication(struct bfd_proto *p, struct bfd_session *s, struct bfd_
/* BFD CSNs are in 32-bit circular number space */
u32 csn = ntohl(auth->csn);
if (s->rx_csn_known &&
- (((csn - s->rx_csn) > (3 * s->detect_mult)) ||
+ (((csn - s->rx_csn) > (3 * (uint) s->detect_mult)) ||
(meticulous && (csn == s->rx_csn))))
{
/* We want to report both new and old CSN */
diff --git a/proto/rip/packets.c b/proto/rip/packets.c
index 9dc492b7..e97809c8 100644
--- a/proto/rip/packets.c
+++ b/proto/rip/packets.c
@@ -450,7 +450,7 @@ rip_send_response(struct rip_proto *p, struct rip_iface *ifa)
/* Stale entries that should be removed */
if ((en->valid == RIP_ENTRY_STALE) &&
- ((en->changed + ifa->cf->garbage_time) <= now))
+ ((en->changed + (bird_clock_t) ifa->cf->garbage_time) <= now))
goto next_entry;
/* Triggered updates */
diff --git a/proto/rip/rip.c b/proto/rip/rip.c
index 157093aa..55fb47c5 100644
--- a/proto/rip/rip.c
+++ b/proto/rip/rip.c
@@ -684,7 +684,7 @@ rip_reconfigure_iface(struct rip_proto *p, struct rip_iface *ifa, struct rip_ifa
rip_iface_update_buffers(ifa);
- if (ifa->next_regular > (now + new->update_time))
+ if (ifa->next_regular > (now + (bird_clock_t) new->update_time))
ifa->next_regular = now + (random() % new->update_time) + 1;
if (new->check_link != old->check_link)