LWIP - udp_io_hdr.h
lwip server needs to include struct udp_io_hdr but must not include struct udp-hdr as it conflicts with its internal type. So it is split into to files now.
This commit is contained in:
parent
3bbd454578
commit
77172e23f7
3 changed files with 23 additions and 11 deletions
|
@ -28,7 +28,7 @@ INCS+= net/gen/arp_io.h net/gen/dhcp.h net/gen/ether.h \
|
||||||
net/gen/psip_hdr.h net/gen/psip_io.h net/gen/resolv.h \
|
net/gen/psip_hdr.h net/gen/psip_io.h net/gen/resolv.h \
|
||||||
net/gen/rip.h net/gen/route.h net/gen/socket.h \
|
net/gen/rip.h net/gen/route.h net/gen/socket.h \
|
||||||
net/gen/tcp.h net/gen/tcp_hdr.h net/gen/tcp_io.h \
|
net/gen/tcp.h net/gen/tcp_hdr.h net/gen/tcp_io.h \
|
||||||
net/gen/udp.h net/gen/udp_hdr.h net/gen/udp_io.h \
|
net/gen/udp.h net/gen/udp_hdr.h net/gen/udp_io.h net/gen/udp_io_hdr.h \
|
||||||
net/gen/vjhc.h
|
net/gen/vjhc.h
|
||||||
|
|
||||||
INCS+= ddekit/assert.h ddekit/initcall.h ddekit/memory.h ddekit/pgtab.h \
|
INCS+= ddekit/assert.h ddekit/initcall.h ddekit/memory.h ddekit/pgtab.h \
|
||||||
|
|
|
@ -5,6 +5,12 @@ server/ip/gen/udp_hdr.h
|
||||||
#ifndef __SERVER__IP__GEN__UDP_HDR_H__
|
#ifndef __SERVER__IP__GEN__UDP_HDR_H__
|
||||||
#define __SERVER__IP__GEN__UDP_HDR_H__
|
#define __SERVER__IP__GEN__UDP_HDR_H__
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Included for compatibility with programs which assume udp_io_hdr_t to be
|
||||||
|
* defined in this header file
|
||||||
|
*/
|
||||||
|
#include "udp_io_hdr.h"
|
||||||
|
|
||||||
typedef struct udp_hdr
|
typedef struct udp_hdr
|
||||||
{
|
{
|
||||||
udpport_t uh_src_port;
|
udpport_t uh_src_port;
|
||||||
|
@ -13,14 +19,4 @@ typedef struct udp_hdr
|
||||||
u16_t uh_chksum;
|
u16_t uh_chksum;
|
||||||
} udp_hdr_t;
|
} udp_hdr_t;
|
||||||
|
|
||||||
typedef struct udp_io_hdr
|
|
||||||
{
|
|
||||||
ipaddr_t uih_src_addr;
|
|
||||||
ipaddr_t uih_dst_addr;
|
|
||||||
udpport_t uih_src_port;
|
|
||||||
udpport_t uih_dst_port;
|
|
||||||
u16_t uih_ip_opt_len;
|
|
||||||
u16_t uih_data_len;
|
|
||||||
} udp_io_hdr_t;
|
|
||||||
|
|
||||||
#endif /* __SERVER__IP__GEN__UDP_HDR_H__ */
|
#endif /* __SERVER__IP__GEN__UDP_HDR_H__ */
|
||||||
|
|
16
common/include/net/gen/udp_io_hdr.h
Normal file
16
common/include/net/gen/udp_io_hdr.h
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
#ifndef __SERVER__IP__GEN__UDP_IO_HDR_H__
|
||||||
|
#define __SERVER__IP__GEN__UDP_IO_HDR_H__
|
||||||
|
|
||||||
|
|
||||||
|
typedef struct udp_io_hdr
|
||||||
|
{
|
||||||
|
ipaddr_t uih_src_addr;
|
||||||
|
ipaddr_t uih_dst_addr;
|
||||||
|
udpport_t uih_src_port;
|
||||||
|
udpport_t uih_dst_port;
|
||||||
|
u16_t uih_ip_opt_len;
|
||||||
|
u16_t uih_data_len;
|
||||||
|
} udp_io_hdr_t;
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __SERVER__IP__GEN__UDP_IO_HDR_H__ */
|
Loading…
Reference in a new issue