summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOndrej Filip <feela@network.cz>2000-06-08 04:04:45 +0200
committerOndrej Filip <feela@network.cz>2000-06-08 04:04:45 +0200
commit59ba3342968fdd2a016b192559a64439281e25bf (patch)
tree1f092240041772734a11090f0870c1c9c23e39f4
parent423230f2f1080c6a4f6d05b6d7705cfaee500f48 (diff)
downloadbird-59ba3342968fdd2a016b192559a64439281e25bf.tar
bird-59ba3342968fdd2a016b192559a64439281e25bf.zip
I forgot some endianity operations.
-rw-r--r--proto/ospf/hello.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/proto/ospf/hello.c b/proto/ospf/hello.c
index 09dbfae..0cdaab7 100644
--- a/proto/ospf/hello.c
+++ b/proto/ospf/hello.c
@@ -93,8 +93,8 @@ ospf_hello_rx(struct ospf_hello_packet *ps, struct proto *p,
add_tail(&ifa->neigh_list, NODE n);
n->rid=nrid;
n->ip=faddr;
- n->dr=ntohl(ps->dr);
- n->bdr=ntohl(ps->bdr);
+ n->dr=ipa_ntoh(ps->dr);
+ n->bdr=ipa_ntoh(ps->bdr);
n->priority=ps->priority;
n->options=ps->options;
n->ifa=ifa;
@@ -141,9 +141,9 @@ ospf_hello_rx(struct ospf_hello_packet *ps, struct proto *p,
if(!twoway) ospf_neigh_sm(n, INM_1WAYREC);
olddr = n->dr;
- n->dr = ntohl(ps->dr);
+ n->dr = ipa_ntoh(ps->dr);
oldbdr = n->bdr;
- n->bdr = ntohl(ps->bdr);
+ n->bdr = ipa_ntoh(ps->bdr);
oldpriority = n->priority;
n->priority = ps->priority;
@@ -213,8 +213,8 @@ hello_timer_hook(timer *timer)
pkt->options=ifa->options;
pkt->priority=ifa->priority;
pkt->deadint=htonl(ifa->deadc*ifa->helloint);
- pkt->dr=htonl(ifa->drip);
- pkt->bdr=htonl(ifa->bdrip);
+ pkt->dr=ipa_hton(ifa->drip);
+ pkt->bdr=ipa_hton(ifa->bdrip);
/* Fill all neighbors */
i=0;