Bug #4691
closed
NLSR crashes due to FATAL error about CanBePrefix being unset in an Interest
Added by Eric Newberry over 6 years ago.
Updated about 6 years ago.
Description
It appears that NLSR is sending Interests with CanBePrefix unset, which is seemingly disallowed according to the error message that is being outputted:
FATAL: [nlsr.NlsrRunner] ERROR: Interest.CanBePrefix is unset
This was seen when using the latest git HEAD versions of ndn-cxx, ChronoSync, and NLSR with Mini-NDN.
Hmm, is ndn-cxx compiled with tests?:
I see this in interest.cpp:
#ifdef NDN_CXX_HAVE_TESTS
if (s_errorIfCanBePrefixUnset) {
BOOST_THROW_EXCEPTION(std::logic_error("Interest.CanBePrefix is unset"));
}
#endif // NDN_CXX_HAVE_TESTS
Ashlesh Gawande wrote:
Hmm, is ndn-cxx compiled with tests?:
Yes it is in my case.
Hmm, is ndn-cxx compiled with tests?:
Yes it is in my case.
You shouldn't use tests-enabled ndn-cxx with other projects. See https://yoursunny.com/t/2017/NFD-devbox/ "./waf configure" section for recommended setup.
Junxiao Shi wrote:
Hmm, is ndn-cxx compiled with tests?:
Yes it is in my case.
You shouldn't use tests-enabled ndn-cxx with other projects. See https://yoursunny.com/t/2017/NFD-devbox/ "./waf configure" section for recommended setup.
I disagree - tests-enabled ndn-cxx shouldn't break other projects.
Test mode is to test the library/project itself, so I wouldn't agree with this. And this specific crash was, actually, useful to fix the issue with the packet format transition.
Ashlesh Gawande wrote:
Does this fix it:
https://gerrit.named-data.net/#/c/NLSR/+/4893/?
No, although the issue appears in a different place:
DEBUG: [nlsr.HelloProtocol] Scheduling HELLO Interests in 10 seconds
WARNING: Interest.CanBePrefix will be set to 0 in the near future. Please declare a preferred setting via Interest::setDefaultCanBePrefix.ERROR: Interest.CanBePrefix is unset
Hmm, maybe Chronosync then - let me look into it and see if I can push a change.
- Status changed from New to Code review
- % Done changed from 0 to 100
- Status changed from Code review to Closed
- Target version set to v0.5.0
Also available in: Atom
PDF