[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Bug found in ns-2.0a17 ?



Hello ns-programmers,

I guess I found a little bug in ns-2. When starting
ns-2.0a17-current/tcl/ex/simple-src.tcl, I get the following
results: (we have one multicast-sender "0" to which three
receivers "1", "2" and "3" are directly attached).


v 0.5 eval {set sim_annotation {0 join group 32768}}
v 1 eval {set sim_annotation {1 join group 32768}}
+ 1.03697 0 1 cbr 210 ----- 0 0.1 128.0 0 0
- 1.03697 0 1 cbr 210 ----- 0 0.1 128.0 0 0
+ 1.03697 0 2 cbr 210 ----- 0 0.1 128.0 0 0
- 1.03697 0 2 cbr 210 ----- 0 0.1 128.0 0 0
+ 1.03697 0 3 cbr 210 ----- 0 0.1 128.0 0 0
- 1.03697 0 3 cbr 210 ----- 0 0.1 128.0 0 0
+ 1.04809 2 0 graft 80 ----- 30 2.0 0.0 -1 1
- 1.04809 2 0 graft 80 ----- 30 2.0 0.0 -1 1
+ 1.04809 3 0 graft 80 ----- 30 3.0 0.0 -1 2
- 1.04809 3 0 graft 80 ----- 30 3.0 0.0 -1 2
+ 1.05377 0 1 cbr 210 ----- 0 0.1 128.0 1 3
- 1.05377 0 1 cbr 210 ----- 0 0.1 128.0 1 3
+ 1.05377 0 2 cbr 210 ----- 0 0.1 128.0 1 3
- 1.05377 0 2 cbr 210 ----- 0 0.1 128.0 1 3
+ 1.05377 0 3 cbr 210 ----- 0 0.1 128.0 1 3
- 1.05377 0 3 cbr 210 ----- 0 0.1 128.0 1 3
+ 1.06489 2 0 graft 80 ----- 30 2.0 0.0 -1 4
- 1.06489 2 0 graft 80 ----- 30 2.0 0.0 -1 4
+ 1.06489 3 0 graft 80 ----- 30 3.0 0.0 -1 5
- 1.06489 3 0 graft 80 ----- 30 3.0 0.0 -1 5
+ 1.07057 0 1 cbr 210 ----- 0 0.1 128.0 2 6
- 1.07057 0 1 cbr 210 ----- 0 0.1 128.0 2 6
+ 1.08737 0 1 cbr 210 ----- 0 0.1 128.0 3 7
- 1.08737 0 1 cbr 210 ----- 0 0.1 128.0 3 7


Now, as only receivers 0 and 1 join (see first two lines) the
multicast group, I expected the other two receivers
2 and 3 to send a prune, but instead they send a graft (lines
9 and 11).
However, the multicast tree prunes back correctly, as can
be seen when looking at the last two lines, where obviously
the following packets are only forwarded to receiver 1.

I guess I figured out the problem: In prune.cc we have
in the constructor:

PruneAgent::PruneAgent() : Agent(PT_GRAFT)
{
  [...]
}

That doesn't seem right - does it?

Maybe someone can take into account the prob.

Another minor thing: Shouldn't the function

     recv(...)

in "class Agent" be declared virtual (derived classes
like SRMAgent re-implement it!)?

    - Chris.