No need to make NetDevice::SendFrom pure virtual; instead just give a fatal error if used in runtime (it's only used by the learning bridge, anyway, so...).
This commit is contained in:
1 parent
c3987ca6d0
commit
ca47bdc908
4 files changed
+7
-8
No files matched your search
@@ -52,5 +52,11 @@ NetDevice::SetPromiscReceiveCallback (PromiscReceiveCallback cb)
|
||||
NS_ASSERT (!SupportsPromiscuous ());
|
||||
}
|
||||
|
||||
bool
|
||||
NetDevice::SendFrom (Ptr<Packet> packet, const Address& source, const Address& dest, uint16_t protocolNumber)
|
||||
{
|
||||
NS_FATAL_ERROR ("NetDevice::SendFrom not implemented for " << GetInstanceTypeId ().GetName ());
|
||||
return false;
|
||||
}
|
||||
|
||||
} // namespace ns3
|
||||
@@ -228,7 +228,7 @@ public:
|
||||
*
|
||||
* \return whether the Send operation succeeded
|
||||
*/
|
||||
virtual bool SendFrom(Ptr<Packet> packet, const Address& source, const Address& dest, uint16_t protocolNumber) = 0;
|
||||
virtual bool SendFrom(Ptr<Packet> packet, const Address& source, const Address& dest, uint16_t protocolNumber);
|
||||
/**
|
||||
* \returns the node base class which contains this network
|
||||
* interface.
|
||||
|
||||
Reference in new issue
Block a user