2

I think there is a bug in OLSR::degree() method:

This method calculates the number of symmetric neighbors of node y, EXCLUDING all the members of N.

I think

OLSR_nb_tuple* nb_tuple =
state_.find_nb_tuple(nb2hop_tuple->nb_main_addr());

should be

OLSR_nb_tuple* nb_tuple =
state_.find_nb_tuple(nb2hop_tuple->2_hop_addr());

Am I right?

DarthJDG
  • 16,511
  • 11
  • 49
  • 56
Shushan
  • 21
  • 2

2 Answers2

2

Yes friend, you're right. this is a bug. The correct line is:

OLSR_nb_tuple* nb_tuple =
state_.find_nb_tuple(nb2hop_tuple->2_hop_addr());
DarthJDG
  • 16,511
  • 11
  • 49
  • 56
abdou
  • 21
  • 2
1

i'm using UM-OLSR version 0.8.8 and the fix you guys gave did not compile, the correct way to fix the bug in UM-OLSR version 0.8.8 is:

OLSR_nb_tuple* nb_tuple =
state_.find_nb_tuple(nb2hop_tuple->nb2hop_addr());
DarthJDG
  • 16,511
  • 11
  • 49
  • 56