ns-allinone-2.35/ns-2.35/linkstate/ls.cc
void LsRouting::sendTopo(int neighborId) 
{
	// if we've gone so far, messageCenterPtr should not be null, 
	// don't check
	LsMessage* msgPtr= msgctr().newMessage(myNodeId_, LS_MSG_TPM);
	// XXX, here we are going to send the pointer that points
	// to my own topo, because sending the who topomap is too costly in
	// simulation
	msgPtr->contentPtr_ = &linkStateDatabase_;
	bufferedSend(neighborId, msgPtr);
}
// After a link comes up, receive Topo with the corresponding neighbor
After a link comes up, receive Topo with the corresponding neighbor
After a link comes up receive Topo with the corresponding neighbor
void LsRouting::sendTopo(int neighborId) 
{
	LsMessage* msgPtr= msgctr().newMessage(myNodeId_, LS_MSG_TPM);
	msgPtr->contentPtr_ = &linkStateDatabase_;
	bufferedSend(neighborId, msgPtr);
}
void LsRouting :: sendTopo ( int neighborId ) { LsMessage * msgPtr = msgctr ( ) . newMessage ( myNodeId_ , LS_MSG_TPM ) ; msgPtr -> contentPtr_ = & linkStateDatabase_ ; bufferedSend ( neighborId , msgPtr ) ; }
After a link comes up, receive Topo with the corresponding neighbor
After a link comes up receive Topo with the corresponding neighbor
// if we've gone so far, messageCenterPtr should not be null,  // don't check // XXX, here we are going to send the pointer that points // to my own topo, because sending the who topomap is too costly in // simulation