mesh: Improve logging
This commit is contained in:
@@ -110,6 +110,7 @@ MeshPointDevice::ReceiveFromDevice (Ptr<NetDevice> incomingPort, Ptr<const Packe
|
||||
if (m_routingProtocol->RemoveRoutingStuff (incomingPort->GetIfIndex (), src48, dst48, packet_copy, realProtocol))
|
||||
{
|
||||
m_rxCallback (this, packet_copy, realProtocol, src);
|
||||
NS_LOG_DEBUG ("Forwarding from " << src48 << " to " << dst48 << " at " << m_address);
|
||||
Forward (incomingPort, packet, protocol, src48, dst48);
|
||||
|
||||
m_rxStats.broadcastData++;
|
||||
@@ -136,9 +137,15 @@ void
|
||||
MeshPointDevice::Forward (Ptr<NetDevice> inport, Ptr<const Packet> packet, uint16_t protocol,
|
||||
const Mac48Address src, const Mac48Address dst)
|
||||
{
|
||||
NS_LOG_FUNCTION (this << inport << packet << protocol << src << dst);
|
||||
// pass through routing protocol
|
||||
m_routingProtocol->RequestRoute (inport->GetIfIndex (), src, dst, packet, protocol, MakeCallback (
|
||||
NS_LOG_DEBUG ("Forwarding from " << src << " to " << dst << " at " << m_address);
|
||||
bool result = m_routingProtocol->RequestRoute (inport->GetIfIndex (), src, dst, packet, protocol, MakeCallback (
|
||||
&MeshPointDevice::DoSend, this));
|
||||
if (result == false)
|
||||
{
|
||||
NS_LOG_DEBUG ("Request to forward packet " << packet << " to destination " << dst << " failed; dropping packet");
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
|
||||
Reference in New Issue
Block a user