[Olsr-cvs] olsrd-current/src lq_packet.c, 1.24, 1.25 link_set.c, 1.69, 1.70
Bernd Petrovitsch
(spam-protected)
Sun Aug 19 22:37:43 CEST 2007
Update of /cvsroot/olsrd/olsrd-current/src
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv32515/src
Modified Files:
lq_packet.c link_set.c
Log Message:
applied
110-olsrd-double-wlancard-neigh-hack.patch,
111-olsrd-complainpluginvers-nosleep.patch,
112-olsrd-nameservice-fixemptyname.patch,
113-olsrd-dyngwplain-pluginvers5.patch and
140-olsrd-arprefreshed.patch
from http://download-master.berlin.freifunk.net/sven-ola/nylon/packages/olsrd/files/
Index: lq_packet.c
===================================================================
RCS file: /cvsroot/olsrd/olsrd-current/src/lq_packet.c,v
retrieving revision 1.24
retrieving revision 1.25
diff -C2 -d -r1.24 -r1.25
*** lq_packet.c 2 Aug 2007 22:07:19 -0000 1.24
--- lq_packet.c 19 Aug 2007 20:37:41 -0000 1.25
***************
*** 312,316 ****
unsigned char *buff;
int is_first;
! int i, j;
if (lq_hello == NULL || outif == NULL)
--- 312,316 ----
unsigned char *buff;
int is_first;
! int i;
if (lq_hello == NULL || outif == NULL)
***************
*** 361,369 ****
for (i = 0; i <= MAX_NEIGH; i++)
{
! for(j = 0; j <= MAX_LINK; j++)
{
- if(j == HIDE_LINK)
- continue;
-
is_first = 1;
--- 361,368 ----
for (i = 0; i <= MAX_NEIGH; i++)
{
! static const int LINK_ORDER[] = {SYM_LINK, UNSPEC_LINK, ASYM_LINK, LOST_LINK};
! unsigned int j;
! for(j = 0; j < sizeof(LINK_ORDER) / sizeof(LINK_ORDER[0]); j++)
{
is_first = 1;
***************
*** 372,376 ****
for (neigh = lq_hello->neigh; neigh != NULL; neigh = neigh->next)
{
! if (neigh->neigh_type != i || neigh->link_type != j)
continue;
--- 371,375 ----
for (neigh = lq_hello->neigh; neigh != NULL; neigh = neigh->next)
{
! if (neigh->neigh_type != i || neigh->link_type != LINK_ORDER[j])
continue;
***************
*** 427,431 ****
info_head->reserved = 0;
! info_head->link_code = CREATE_LINK_CODE(i, j);
}
--- 426,430 ----
info_head->reserved = 0;
! info_head->link_code = CREATE_LINK_CODE(i, LINK_ORDER[j]);
}
Index: link_set.c
===================================================================
RCS file: /cvsroot/olsrd/olsrd-current/src/link_set.c,v
retrieving revision 1.69
retrieving revision 1.70
diff -C2 -d -r1.69 -r1.70
*** link_set.c 2 Aug 2007 22:07:19 -0000 1.69
--- link_set.c 19 Aug 2007 20:37:41 -0000 1.70
***************
*** 795,798 ****
--- 795,799 ----
check_link_status(struct hello_message *message, struct interface *in_if)
{
+ int ret = UNSPEC_LINK;
struct hello_neighbor *neighbors;
***************
*** 801,808 ****
while(neighbors!=NULL)
{
if(COMP_IP(&neighbors->address, &in_if->ip_addr))
{
//printf("ok");
! return neighbors->link;
}
--- 802,814 ----
while(neighbors!=NULL)
{
+ /*
+ * Note: If a neigh has 2 cards we can reach, the neigh
+ * will send a Hello with the same IP mentined twice
+ */
if(COMP_IP(&neighbors->address, &in_if->ip_addr))
{
//printf("ok");
! ret = neighbors->link;
! if (SYM_LINK == ret) break;
}
***************
*** 811,815 ****
! return UNSPEC_LINK;
}
--- 817,821 ----
! return ret;
}
More information about the Olsr-cvs
mailing list