Closed CHTJonas closed 3 years ago
We allocate a fixed-size 512-byte array into which ICMP messages are deserialised.
https://github.com/go-ping/ping/blob/b6486c6f1f2d7aa4e017c9571730d467c4d4a2b8/ping.go#L475
This causes message truncation for people who ping with a larger message size and needless memory pressure for people who ping with one that's smaller.
We allocate a fixed-size 512-byte array into which ICMP messages are deserialised.
https://github.com/go-ping/ping/blob/b6486c6f1f2d7aa4e017c9571730d467c4d4a2b8/ping.go#L475
This causes message truncation for people who ping with a larger message size and needless memory pressure for people who ping with one that's smaller.