From e61d0273c0601c72a094f04c5553f29aab6cc831 Mon Sep 17 00:00:00 2001 From: Morteza Kheirkhah Date: Thu, 3 Jul 2014 12:20:36 +0100 Subject: [PATCH] mod 60 has been added --- src/internet/model/mp-tcp-socket-base.cc | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/src/internet/model/mp-tcp-socket-base.cc b/src/internet/model/mp-tcp-socket-base.cc index e7eaba4..d5ef7d1 100644 --- a/src/internet/model/mp-tcp-socket-base.cc +++ b/src/internet/model/mp-tcp-socket-base.cc @@ -86,6 +86,14 @@ MpTcpSocketBase::MpTcpSocketBase(Ptr node) : nextRxSequence = 1; gnu.SetOutFile("allPlots.pdf"); pAck = 0; + mod = 60; + Callback > vPS = MakeNullCallback >(); + Callback, const Address &> vPSA = MakeNullCallback, const Address &>(); + Callback, uint32_t> vPSUI = MakeNullCallback, uint32_t>(); + SetConnectCallback(vPS, vPS); + SetDataSentCallback(vPSUI); + SetSendCallback(vPSUI); + SetRecvCallback(vPS); } MpTcpSocketBase::~MpTcpSocketBase(void) @@ -3343,16 +3351,17 @@ MpTcpSocketBase::FindOutputNetDevice(Ipv4Address src) { NS_LOG_INFO("FindOutputNetDevice"); - return 0; -// Ptr ipv4 = m_node->GetObject(); -// uint32_t oInterface = ipv4->GetInterfaceForAddress(src); -// Ptr oNetDevice = ipv4->GetNetDevice(oInterface); +// return 0; + Ptr ipv4 = m_node->GetObject(); + uint32_t oInterface = ipv4->GetInterfaceForAddress(src); + Ptr oNetDevice = ipv4->GetNetDevice(oInterface); // Ptr interface = ipv4->GetRealInterfaceForAddress(src); // Ptr netDevice = interface->GetDevice(); // NS_ASSERT(netDevice == oNetDevice); //NS_LOG_INFO("FindNetDevice -> Src: " << src << " NIC: " << netDevice->GetAddress()); -// return oNetDevice; + //return oNetDevice; + return 0; } bool