Skip to content

Commit

Permalink
revert a breaking change (#511)
Browse files Browse the repository at this point in the history
  • Loading branch information
homuler committed Apr 5, 2022
1 parent 81fe7f8 commit e1a908d
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,7 @@ protected override void DeleteMpPtr()
UnsafeNativeMethods.mp_Packet__At__Rt(mpPtr, timestamp.mpPtr, out var packetPtr).Assert();
GC.KeepAlive(timestamp);

var packet = Create<TPacket>(packetPtr, true);
Dispose();
return packet;
return Create<TPacket>(packetPtr, true);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ public void At_ShouldReturnNewPacketWithTimestamp()
Assert.AreEqual(newPacket.Timestamp(), newTimestamp);
}

Assert.True(packet.isDisposed);
Assert.AreEqual(packet.Timestamp(), timestamp);
}
}
#endregion
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public void At_ShouldReturnNewPacketWithTimestamp()
Assert.AreEqual(newPacket.Timestamp(), newTimestamp);
}

Assert.True(packet.isDisposed);
Assert.AreEqual(packet.Timestamp(), timestamp);
}
}
#endregion
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ public void At_ShouldReturnNewPacketWithTimestamp()
Assert.AreEqual(newPacket.Timestamp(), newTimestamp);
}

Assert.True(packet.isDisposed);
Assert.AreEqual(packet.Timestamp(), timestamp);
}
}
#endregion
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ public void At_ShouldReturnNewPacketWithTimestamp()
Assert.AreEqual(newPacket.Timestamp(), newTimestamp);
}

Assert.True(packet.isDisposed);
Assert.AreEqual(packet.Timestamp(), timestamp);
}
}
#endregion
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ public void At_ShouldReturnNewPacketWithTimestamp()
Assert.AreEqual(newPacket.Timestamp(), newTimestamp);
}

Assert.True(packet.isDisposed);
Assert.AreEqual(packet.Timestamp(), timestamp);
}
}
#endregion
Expand Down

0 comments on commit e1a908d

Please sign in to comment.