Loading...
Searching...
No Matches
icmp.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2015 José Ignacio Alamos <jialamos@uc.cl>
3 *
4 * This file is subject to the terms and conditions of the GNU Lesser
5 * General Public License v2.1. See the file LICENSE in the top level
6 * directory for more details.
7 */
8
23#ifndef NET_ICMP_H
24#define NET_ICMP_H
25
26#include "byteorder.h"
27
28#ifdef __cplusplus
29extern "C" {
30#endif
31
39typedef struct __attribute__((packed)){
40 uint8_t type;
41 uint8_t code;
46
47#ifdef __cplusplus
48}
49#endif
50
51#endif /* NET_ICMP_H */
Functions to work with different byte orders.
Echo request and response message format.
Definition icmp.h:39
uint8_t type
message type
Definition icmp.h:40
network_uint16_t csum
checksum
Definition icmp.h:42
uint8_t code
message code
Definition icmp.h:41
network_uint16_t sn
sequence number
Definition icmp.h:44
network_uint16_t id
identifier
Definition icmp.h:43
A 16 bit integer in big endian aka network byte order.
Definition byteorder.h:74