Bug 1887 - Point-to-point traces should contain PPP headers

This commit is contained in:
Eugene Chemeritskiy
2014-03-25 21:46:09 +01:00
parent cb9eeb2af2
commit edc382137b
2 changed files with 10 additions and 3 deletions

View File

@@ -61,6 +61,7 @@ Bugs fixed
- Bug 1874 - Ipv4L3Protocol::ProcessFragment: addressCombination and idProto identifiers not properly computed
- Bug 1882 - int64x64 tests trigger valgrind bug
- Bug 1883 - IPv6 don't consider the prefix and network when choosing output address
- Bug 1887 - Point-to-point traces should contain PPP headers
Release 3.19
=============

View File

@@ -318,13 +318,19 @@ PointToPointNetDevice::Receive (Ptr<Packet> packet)
{
//
// Hit the trace hooks. All of these hooks are in the same place in this
// device becuase it is so simple, but this is not usually the case in
// device because it is so simple, but this is not usually the case in
// more complicated devices.
//
m_snifferTrace (packet);
m_promiscSnifferTrace (packet);
m_phyRxEndTrace (packet);
//
// Trace sinks will expect complete packets, not packets without some of the
// headers.
//
Ptr<Packet> originalPacket = packet->Copy ();
//
// Strip off the point-to-point protocol header and forward this packet
// up the protocol stack. Since this is a simple point-to-point link,
@@ -335,11 +341,11 @@ PointToPointNetDevice::Receive (Ptr<Packet> packet)
if (!m_promiscCallback.IsNull ())
{
m_macPromiscRxTrace (packet);
m_macPromiscRxTrace (originalPacket);
m_promiscCallback (this, packet, protocol, GetRemote (), GetAddress (), NetDevice::PACKET_HOST);
}
m_macRxTrace (packet);
m_macRxTrace (originalPacket);
m_rxCallback (this, packet, protocol, GetRemote ());
}
}