1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162
|
#define CONCAT(a, b) a##b
#define CONCAT2(a, b) CONCAT(a, b)
#define STATIC_ASSERT(condition) \
int CONCAT2(some_array, __LINE__)[(condition) ? 1 : -1]
enum {
RTAX_UNSPEC,
RTAX_LOCK,
RTAX_MTU,
RTAX_WINDOW,
RTAX_RTT,
RTAX_RTTVAR,
RTAX_SSTHRESH,
RTAX_CWND,
RTAX_ADVMSS,
RTAX_REORDERING,
RTAX_HOPLIMIT,
RTAX_INITCWND,
RTAX_FEATURES,
RTAX_RTO_MIN,
RTAX_INITRWND,
__RTAX_MAX
};
typedef __signed__ char __s8;
typedef unsigned char __u8;
typedef __signed__ short __s16;
typedef unsigned short __u16;
typedef __signed__ int __s32;
typedef unsigned int __u32;
__extension__ typedef __signed__ long long __s64;
__extension__ typedef unsigned long long __u64;
typedef signed char s8;
typedef unsigned char u8;
typedef signed short s16;
typedef unsigned short u16;
typedef signed int s32;
typedef unsigned int u32;
typedef signed long long s64;
typedef unsigned long long u64;
typedef unsigned char u_char;
typedef unsigned short u_short;
typedef unsigned int u_int;
typedef unsigned long u_long;
typedef unsigned char unchar;
typedef unsigned short ushort;
typedef unsigned int uint;
typedef unsigned long ulong;
typedef __u8 u_int8_t;
typedef __s8 int8_t;
typedef __u16 u_int16_t;
typedef __s16 int16_t;
typedef __u32 u_int32_t;
typedef __s32 int32_t;
typedef __u8 uint8_t;
typedef __u16 uint16_t;
typedef __u32 uint32_t;
typedef __u64 uint64_t;
typedef __u64 u_int64_t;
typedef __s64 int64_t;
typedef unsigned long sector_t;
typedef unsigned long blkcnt_t;
typedef __u16 __le16;
typedef __u16 __be16;
typedef __u32 __le32;
typedef __u32 __be32;
typedef __u64 __le64;
typedef __u64 __be64;
typedef __u16 __sum16;
typedef __u32 __wsum;
typedef unsigned gfp_t;
typedef unsigned fmode_t;
typedef u64 phys_addr_t;
typedef phys_addr_t resource_size_t;
typedef struct {
int counter;
} atomic_t;
struct rcu_head {
struct rcu_head *next;
void (*func)(struct rcu_head *head);
};
struct sk_buff;
struct dst_entry {
struct rcu_head rcu_head;
struct dst_entry *child;
struct net_device *dev;
short error;
short obsolete;
int flags;
unsigned long expires;
unsigned short header_len;
unsigned short trailer_len;
unsigned int rate_tokens;
unsigned long rate_last;
struct dst_entry *path;
struct neighbour *neighbour;
struct hh_cache *hh;
struct xfrm_state *xfrm;
int (*input)(struct sk_buff*);
int (*output)(struct sk_buff*);
struct dst_ops *ops;
u32 metrics[(__RTAX_MAX - 1)];
__u32 tclassid;
long __pad_to_align_refcnt[1];
atomic_t __refcnt;
int __use;
unsigned long lastuse;
union {
struct dst_entry *next;
struct rtable *rt_next;
struct rt6_info *rt6_next;
struct dn_route *dn_next;
};
};
// GCC specific, and doesn't work on Windows
#ifndef _WIN32
#ifdef __GNUC__
STATIC_ASSERT(
sizeof(void *)==8?
(__builtin_offsetof(struct dst_entry,__refcnt) & 63)==0:
1);
#endif
#endif
int main()
{
}
|