|
Bugzilla – Full Text Bug Listing |
| Summary: | Simplify (and clarify) Simulator::Schedule asserts | ||
|---|---|---|---|
| Product: | ns-3 | Reporter: | Tommaso Pecorella <tommaso.pecorella> |
| Component: | core | Assignee: | Peter Barnes <pdbarnes> |
| Status: | RESOLVED FIXED | ||
| Severity: | enhancement | CC: | ns-bugs, tomh |
| Priority: | P3 | ||
| Version: | ns-3-dev | ||
| Hardware: | All | ||
| OS: | All | ||
| Attachments: | patch | ||
fixed in 13605:16a3cb910bdc |
Created attachment 2715 [details] patch In the Simulator::Schedule implementations there are two checks: Time tAbsolute = delay + TimeStep (m_currentTs); NS_ASSERT (tAbsolute.IsPositive ()); NS_ASSERT (tAbsolute >= TimeStep (m_currentTs)); Since m_currentTs is always positive, one is redundant. It is enough to check that delay is positive. Moreover, adding a more explicit error message is needed.