← Back to team overview

rohc team mailing list archive

Re: [Question #216331]: Build failure on 1.5.1

 

Question #216331 on rohc changed:
https://answers.launchpad.net/rohc/+question/216331

    Status: Needs information => Open

Raman Gupta gave more information on the question:
Here are the content of the src/common/protocols/ipv6.h file

/**
 * @file   ipv6.h
 * @brief  Defines the IPv6 header
 * @author Free Software Foundation, Inc
 *
 * This file contains a part of netinet/ip6.h from the GNU C library. It is
 * copied here to be portable on all platforms, even the platforms that miss
 * the declarations or got different declarations, such as Microsoft Windows
 * or FreeBSD.
 */

#ifndef ROHC_PROTOCOLS_IPV6_H
#define ROHC_PROTOCOLS_IPV6_H

#include <stdint.h>


/**
 * @brief The IPv6 address
 */
struct ipv6_addr
{
	union
	{
		uint8_t __u6_addr8[16];
		uint16_t __u6_addr16[8];
		uint32_t __u6_addr32[4];
	} __in6_u;
#define s6_addr		__in6_u.__u6_addr8
#define s6_addr16		__in6_u.__u6_addr16
#define s6_addr32		__in6_u.__u6_addr32
};


/**
 * @brief The IPv6 header
 */
struct ipv6_hdr
{
	union
	{
		struct ip6_hdrctl
		{
			uint32_t ip6_un1_flow;   /* 4 bits version, 8 bits TC,
			                            20 bits flow-ID */
			uint16_t ip6_un1_plen;   /* payload length */
			uint8_t  ip6_un1_nxt;    /* next header */
			uint8_t  ip6_un1_hlim;   /* hop limit */
		} ip6_un1;
		uint8_t ip6_un2_vfc;       /* 4 bits version, top 4 bits tclass */
	} ip6_ctlun;
	struct ipv6_addr ip6_src;     /* source address */
	struct ipv6_addr ip6_dst;     /* destination address */
};

#define ip6_vfc   ip6_ctlun.ip6_un2_vfc
#define ip6_flow  ip6_ctlun.ip6_un1.ip6_un1_flow
#define ip6_plen  ip6_ctlun.ip6_un1.ip6_un1_plen
#define ip6_nxt   ip6_ctlun.ip6_un1.ip6_un1_nxt
#define ip6_hlim  ip6_ctlun.ip6_un1.ip6_un1_hlim
#define ip6_hops  ip6_ctlun.ip6_un1.ip6_un1_hlim

#endif

-- 
You received this question notification because you are a member of ROHC
Team, which is an answer contact for rohc.