|
Bugzilla – Full Text Bug Listing |
| Summary: | InternetStackHelper not compatible with multile Experiments | ||
|---|---|---|---|
| Product: | ns-3 | Reporter: | Tom Henderson <tomh> |
| Component: | helpers | Assignee: | ns-bugs <ns-bugs> |
| Status: | RESOLVED DUPLICATE | ||
| Severity: | normal | ||
| Priority: | P5 | ||
| Version: | ns-3-dev | ||
| Hardware: | All | ||
| OS: | All | ||
To reproduce: run wifi-clear-channel-cmu on ns-3-dev. This constructor: InternetStackHelper::InternetStackHelper () { SetTcp ("ns3::TcpL4Protocol"); static Ipv4StaticRoutingHelper staticRouting; static Ipv4GlobalRoutingHelper globalRouting; static Ipv4ListRoutingHelper listRouting; listRouting.Add (staticRouting, 0); listRouting.Add (globalRouting, -10); SetRoutingHelper (listRouting); } is not compatible with programs that instantiate multiple InternetStackHelper objects. Either some other way to manage the memory of these helper objects is needed, or some logic needs to be added to prevent the listRouting object from redundandly adding these other routing helpers. The code probably should also assert (to catch programming errors) if two items are added at the same integer priority; presently it just pushes back to a std::list.