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

[ns] Creating a new sendpkt routine



Hello all, 
 My troubles with ns continue.. and so will yours with my doubts...:-)
 Latest news is: I've managed to get a handle on the global topology
thanks to you guys, especially Christian Harrer.
 I wanted to make a function by which I could bypass the send routine of
ns, and send packets to whoever my agent wants without depending upon
explicit "connect"s in the tcl file. For this I simply copied from
rtProtoLS (linkstate) 's sendpkt routine which just overwrites the "dst_"
field and then calls target_->recv(p).
 When I do this, I run into the default handler for no-slots in the
classifier. However when I do an explicit "connect" in the tcl file, I get
the expected results, although connect modifies the dst_ field in the same
way as I do (except that connect modifies it in tcl space while I modify
it in C++ space). But that shouldn't be causing problems since I'm doing
nothing other than what the LS module does.

The error dump I get is:
--- Classfier::no-slot{} default handler (tcl/lib/ns-lib.tcl) ---
        _o12: no target for slot -1
        _o12 type: Classifier/Hash/Dest
content dump:
classifier _o12
        0 offset
        0 shift
        2147483647 mask
        3 slots
                slot 0: _o56
                slot 1: _o22
                slot 2: _o52
        -1 default
---------- Finished standard no-slot{} default handler ----------

Any helpers ????

Pavan
------------------------------------------------------------------------------
Pavan Verma                            [email protected]	
Senior Undergraduate                   http://www.cse.iitd.ernet.in/~csu97136
Computer Sc & Engg, IIT Delhi
------------------------------------------------------------------------------