Skip to content

Commit

Permalink
Fix transmission logic
Browse files Browse the repository at this point in the history
Copy paste bug
  • Loading branch information
JohannesDeml committed Apr 22, 2021
1 parent 28d854b commit 7b7becc
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion NetworkBenchmarkDotNet/Libraries/Enet/EchoClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public override void Dispose()

public override void SendMessages(int messageCount, TransmissionType transmissionType)
{
var flags = ENetBenchmark.GetPacketFlags(config.Transmission);
var flags = ENetBenchmark.GetPacketFlags(transmissionType);

// Don't do this in a real-world application, ENet is not thread safe
// send should only be called in the thread that also calls host.Service
Expand Down
2 changes: 1 addition & 1 deletion NetworkBenchmarkDotNet/Libraries/Enet/EchoServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ private void Send(byte[] data, byte channelId, Peer peer)
private void Broadcast(byte[] data, byte channelId, TransmissionType transmissionType)
{
Packet packet = default(Packet);
var flags = ENetBenchmark.GetPacketFlags(config.Transmission);
var flags = ENetBenchmark.GetPacketFlags(transmissionType);

packet.Create(data, data.Length, flags);
host.Broadcast(channelId, ref packet);
Expand Down
2 changes: 1 addition & 1 deletion NetworkBenchmarkDotNet/Libraries/Kcp2k/EchoClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ public override void Dispose()

public override void SendMessages(int messageCount, TransmissionType transmissionType)
{
var channel = Kcp2kBenchmark.GetChannel(config.Transmission);
var channel = Kcp2kBenchmark.GetChannel(transmissionType);

for (int i = 0; i < messageCount; i++)
{
Expand Down
2 changes: 1 addition & 1 deletion NetworkBenchmarkDotNet/Libraries/LiteNetLib/EchoClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ public override void Dispose()

public override void SendMessages(int messageCount, TransmissionType transmissionType)
{
var delivery = LiteNetLibBenchmark.GetDeliveryMethod(config.Transmission);
var delivery = LiteNetLibBenchmark.GetDeliveryMethod(transmissionType);

for (int i = 0; i < messageCount; i++)
{
Expand Down
2 changes: 1 addition & 1 deletion NetworkBenchmarkDotNet/Libraries/LiteNetLib/EchoServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public override void Dispose()

public override void SendMessages(int messageCount, TransmissionType transmissionType)
{
var delivery = LiteNetLibBenchmark.GetDeliveryMethod(config.Transmission);
var delivery = LiteNetLibBenchmark.GetDeliveryMethod(transmissionType);

for (int i = 0; i < messageCount; i++)
{
Expand Down

0 comments on commit 7b7becc

Please sign in to comment.