Icmpv4_socketinclude Icmpv4.SDisconnect from the ICMP layer. While this might take some time to complete, it can never result in an error.
type ipaddr = Ipaddr.V4.tThe type for IP addresses.
input t src dst buffer reacts to the ICMP message in buffer.
listen t addr fn attempts to create an unprivileged listener on IP address addr.
When a packet is received, the callback fn will be called in a fresh background thread. The callback will be provided a buffer containing an IP datagram with an ICMP payload inside.
The thread returned by listen blocks until the stack is disconnected.