#include <icmp.h>
#include <network.h>
#include <ipv4.h>
#include <string.h>
syscall icmpEchoReply |
( |
struct packet * |
pkt | ) |
|
Send an ICMP Echo Reply in response to the specified ICMP Echo Request.
- Parameters
-
pkt | Pointer to the packet for an ICMP echo request. This packet buffer is re-used for sending the reply. pkt->curr must point to the beginning of the the ICMP header, whereas pkt->len must be the length of the entire packet including link-level header. These members will be updated by this function, and the ICMP type field and checksum will be modified; however, ownership of the packet is not taken and it still must be freed by the caller. |
- Returns
- ::OK if packet was successfully sent; otherwise ::SYSERR or another error code returned by icmpSend().