summaryrefslogtreecommitdiff
path: root/ospf6d/ospf6_message.c
diff options
context:
space:
mode:
authorLou Berger <lberger@labn.net>2018-03-06 14:02:52 -0500
committerLou Berger <lberger@labn.net>2018-03-06 14:04:32 -0500
commit996c93142d3abfab0f6d6c800474e22a8cfbdbc5 (patch)
tree2b28846d256c84cf7b7f1a8988fb3267c8611722 /ospf6d/ospf6_message.c
parent3380418fa10556ef2c9139d09b9a435db64dc392 (diff)
*: conform with COMMUNITY.md formatting rules, via 'make indent'
Signed-off-by: Lou Berger <lberger@labn.net>
Diffstat (limited to 'ospf6d/ospf6_message.c')
-rw-r--r--ospf6d/ospf6_message.c58
1 files changed, 32 insertions, 26 deletions
diff --git a/ospf6d/ospf6_message.c b/ospf6d/ospf6_message.c
index fe74ddc982..b75d5b70fa 100644
--- a/ospf6d/ospf6_message.c
+++ b/ospf6d/ospf6_message.c
@@ -1997,9 +1997,9 @@ static void ospf6_send_lsupdate(struct ospf6_neighbor *on,
if (on) {
on->ospf6_if->ls_upd_out++;
- if ((on->ospf6_if->state == OSPF6_INTERFACE_POINTTOPOINT) ||
- (on->ospf6_if->state == OSPF6_INTERFACE_DR) ||
- (on->ospf6_if->state == OSPF6_INTERFACE_BDR)) {
+ if ((on->ospf6_if->state == OSPF6_INTERFACE_POINTTOPOINT)
+ || (on->ospf6_if->state == OSPF6_INTERFACE_DR)
+ || (on->ospf6_if->state == OSPF6_INTERFACE_BDR)) {
ospf6_send(on->ospf6_if->linklocal_addr,
&allspfrouters6, on->ospf6_if, oh);
} else {
@@ -2010,9 +2010,9 @@ static void ospf6_send_lsupdate(struct ospf6_neighbor *on,
oi->ls_upd_out++;
- if ((oi->state == OSPF6_INTERFACE_POINTTOPOINT) ||
- (oi->state == OSPF6_INTERFACE_DR) ||
- (oi->state == OSPF6_INTERFACE_BDR)) {
+ if ((oi->state == OSPF6_INTERFACE_POINTTOPOINT)
+ || (oi->state == OSPF6_INTERFACE_DR)
+ || (oi->state == OSPF6_INTERFACE_BDR)) {
ospf6_send(oi->linklocal_addr, &allspfrouters6, oi, oh);
} else {
ospf6_send(oi->linklocal_addr, &alldrouters6, oi, oh);
@@ -2065,8 +2065,10 @@ int ospf6_lsupdate_send_neighbor(struct thread *thread)
memset(sendbuf, 0, iobuflen);
oh = (struct ospf6_header *)sendbuf;
- lsupdate = (struct ospf6_lsupdate *)((caddr_t)oh
- + sizeof(struct ospf6_header));
+ lsupdate = (struct ospf6_lsupdate
+ *)((caddr_t)oh
+ + sizeof(struct
+ ospf6_header));
p = (u_char *)((caddr_t)lsupdate
+ sizeof(struct ospf6_lsupdate));
@@ -2110,8 +2112,8 @@ int ospf6_lsupdate_send_neighbor(struct thread *thread)
oh->length = htons(p - sendbuf);
lsupdate->lsa_number = htonl(lsa_cnt);
- if (on->ospf6_if->state ==
- OSPF6_INTERFACE_POINTTOPOINT) {
+ if (on->ospf6_if->state
+ == OSPF6_INTERFACE_POINTTOPOINT) {
ospf6_send(on->ospf6_if->linklocal_addr,
&allspfrouters6,
on->ospf6_if, oh);
@@ -2123,10 +2125,12 @@ int ospf6_lsupdate_send_neighbor(struct thread *thread)
memset(sendbuf, 0, iobuflen);
oh = (struct ospf6_header *)sendbuf;
- lsupdate = (struct ospf6_lsupdate *)((caddr_t)oh
- + sizeof(struct ospf6_header));
- p = (u_char *)((caddr_t)lsupdate +
- sizeof(struct ospf6_lsupdate));
+ lsupdate = (struct ospf6_lsupdate
+ *)((caddr_t)oh
+ + sizeof(struct
+ ospf6_header));
+ p = (u_char *)((caddr_t)lsupdate
+ + sizeof(struct ospf6_lsupdate));
lsa_cnt = 0;
}
}
@@ -2186,11 +2190,11 @@ int ospf6_lsupdate_send_neighbor_now(struct ospf6_neighbor *on,
oh->length = htons(p - sendbuf);
lsupdate->lsa_number = htonl(lsa_cnt);
- if (IS_OSPF6_DEBUG_FLOODING ||
- IS_OSPF6_DEBUG_MESSAGE(OSPF6_MESSAGE_TYPE_LSUPDATE, SEND))
+ if (IS_OSPF6_DEBUG_FLOODING
+ || IS_OSPF6_DEBUG_MESSAGE(OSPF6_MESSAGE_TYPE_LSUPDATE, SEND))
zlog_debug("%s: Send lsupdate with lsa %s (age %u)",
- __PRETTY_FUNCTION__, lsa->name,
- ntohs(lsa->header->age));
+ __PRETTY_FUNCTION__, lsa->name,
+ ntohs(lsa->header->age));
ospf6_send_lsupdate(on, NULL, oh);
@@ -2241,18 +2245,20 @@ int ospf6_lsupdate_send_interface(struct thread *thread)
ospf6_send_lsupdate(NULL, oi, oh);
if (IS_OSPF6_DEBUG_MESSAGE(
- OSPF6_MESSAGE_TYPE_LSUPDATE, SEND))
+ OSPF6_MESSAGE_TYPE_LSUPDATE, SEND))
zlog_debug("%s: LSUpdate length %d",
__PRETTY_FUNCTION__,
ntohs(oh->length));
memset(sendbuf, 0, iobuflen);
oh = (struct ospf6_header *)sendbuf;
- lsupdate = (struct ospf6_lsupdate *)((caddr_t)oh
- + sizeof(struct ospf6_header));
+ lsupdate = (struct ospf6_lsupdate
+ *)((caddr_t)oh
+ + sizeof(struct
+ ospf6_header));
p = (u_char *)((caddr_t)lsupdate
- + sizeof(struct ospf6_lsupdate));
+ + sizeof(struct ospf6_lsupdate));
lsa_cnt = 0;
}
}
@@ -2324,13 +2330,13 @@ int ospf6_lsack_send_neighbor(struct thread *thread)
on->ospf6_if->ls_ack_out++;
ospf6_send(on->ospf6_if->linklocal_addr,
- &on->linklocal_addr,
- on->ospf6_if, oh);
+ &on->linklocal_addr, on->ospf6_if,
+ oh);
memset(sendbuf, 0, iobuflen);
oh = (struct ospf6_header *)sendbuf;
- p = (u_char *)((caddr_t)oh +
- sizeof(struct ospf6_header));
+ p = (u_char *)((caddr_t)oh
+ + sizeof(struct ospf6_header));
lsa_cnt = 0;
}
}