xtables-addons: update to v2.1, fix compilation against Linux 3.7.2, refresh patches
[openwrt/svn-archive/archive.git] / net / xtables-addons / patches / 300-geoip-endian-detection.patch
1 --- a/extensions/libxt_geoip.c
2 +++ b/extensions/libxt_geoip.c
3 @@ -59,13 +59,13 @@ geoip_get_subnets(const char *code, uint
4
5 /* Use simple integer vector files */
6 if (nfproto == NFPROTO_IPV6) {
7 -#if __BYTE_ORDER == _BIG_ENDIAN
8 +#if BYTE_ORDER == BIG_ENDIAN
9 snprintf(buf, sizeof(buf), GEOIP_DB_DIR "/BE/%s.iv6", code);
10 #else
11 snprintf(buf, sizeof(buf), GEOIP_DB_DIR "/LE/%s.iv6", code);
12 #endif
13 } else {
14 -#if __BYTE_ORDER == _BIG_ENDIAN
15 +#if BYTE_ORDER == BIG_ENDIAN
16 snprintf(buf, sizeof(buf), GEOIP_DB_DIR "/BE/%s.iv4", code);
17 #else
18 snprintf(buf, sizeof(buf), GEOIP_DB_DIR "/LE/%s.iv4", code);