Error interpretation

16 views
Skip to first unread message

omowunmi longe

unread,
Apr 10, 2014, 3:46:29 AM4/10/14
to ns-3-...@googlegroups.com
Hello,
PLease can you help me interprete this error when I used the gdb debugger:
#0  0x00007ffff1013f2e in ns3::Object::CheckLoose (this=0x66e530)
    at ../src/core/model/object.cc:367
#1  0x00007ffff1011e17 in ns3::Object::DoGetObject (this=0x66e530, tid=...)
    at ../src/core/model/object.cc:148
#2  0x00007ffff1411db9 in ns3::Object::GetObject<ns3::SocketFactory> (
    this=0x66e530, tid=...) at ./ns3/object.h:354
#3  0x00007ffff1409dac in ns3::Socket::CreateSocket (node=..., tid=...)
    at ../src/network/model/socket.cc:75
#4  0x000000000040d9e3 in main (argc=2, argv=0x7fffffffdeb8)
    at ../scratch/wifi3.cc:215

Thanks.

--
O.M.Longe

Tommaso Pecorella

unread,
Apr 10, 2014, 2:46:30 PM4/10/14
to ns-3-...@googlegroups.com
Hi,


/* In some cases, when an event is scheduled against a subclass of
 * Object, and if no one owns a reference directly to this object, the
 * object is alive, has a refcount of zero and the method ran when the
 * event expires runs against the raw pointer which means that we are
 * manipulating an object with a refcount of zero.  So, instead we
 * check the aggregate reference count.
 */


bool Object::CheckLoose (void) const

That's how a SmartPointer is telling you to not use a zero-pointer ...

Now, let's be a less cryptic.

A smart pointer shouldn't throw this. Unless you did something quite bad with the Smart Pointer itself. More or less it's like using pointer after deleting it.
Double check your code.

Cheers,

T.
Reply all
Reply to author
Forward
0 new messages