Cannot receive packets via EOS P2P despite PacketQueue being filled with size of incoming packet

Hello, I’m using latest 1.16 EOS SDK for C#,
And I’m encountering this error:

EOS PACKET> size: 38 bytes, 
- [EOS LOG] (Error): EOS_P2P_ReceivePacket - One or more parameters are null
EOS PACKET> result: InvalidParameters
EOS PACKET> data size: 0

Given the following code:

I can confirm that the EOS P2P Connects with other DeviceId user via AddNotifyPeerConnectionRequest and AddNotifyPeerConnectionEstablished.

+ EOS> Connection with <00...17d> accepted. (NewConnection)

as well as Disconnects via AddNotifyPeerConnectionClosed.

+  EOS> Connection with <00...17d> closed.

I’ve also tried using the following EOS SDK C# versions:
1.16.1-CL30020700 (latest), 1.16.1, 1.16.0

Also I am unable to log in to EOS Forums to report this issue due to other website’s bug

Oh my, I’ve made such a small mistake that caused so much issues.

In the provided image with code, I set ArraySegment<byte> receivePacketBuffer to new(), while it was supposed to be new byte[P2PInterface.MaxSinglePacketSize];

1 Like