ULE should not make use of the adaptation field.
This commit is contained in:
parent
8c76f9a421
commit
30166ad8da
@ -18,6 +18,7 @@ namespace skyscraper8.Ietf.Rfc4236_ULE
|
||||
/// <param name="errorNo">
|
||||
/// Set this to:
|
||||
/// 1* for a CRC error.
|
||||
/// 2* for an invalid adaptation field control.
|
||||
/// </param>
|
||||
void OnUleError(int pid, int errorNo);
|
||||
}
|
||||
|
||||
@ -27,7 +27,11 @@ namespace skyscraper8.Ietf.Rfc4236_ULE
|
||||
|
||||
public void PushPacket(TsPacket packet)
|
||||
{
|
||||
|
||||
if (packet.AdaptionFieldControl != 1)
|
||||
{
|
||||
_eventHandler.OnUleError(_pid, 2);
|
||||
return;
|
||||
}
|
||||
if (packet.PayloadUnitStart)
|
||||
{
|
||||
PushPusiPacket(packet);
|
||||
@ -161,7 +165,7 @@ namespace skyscraper8.Ietf.Rfc4236_ULE
|
||||
PhysicalAddress source = new PhysicalAddress(ms.ReadBytes(6));
|
||||
ushort etherType = ms.ReadUInt16BE();
|
||||
byte[] contents = ms.ReadBytes(ms.GetAvailableBytes());
|
||||
//_eventHandler.OnEthernetFrame(_pid, destination, source, etherType, contents);
|
||||
_eventHandler.OnEthernetFrame(_pid, destination, source, etherType, contents);
|
||||
}
|
||||
|
||||
public void PacketLoss()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user