X-Git-Url: http://git.ozo.com/?a=blobdiff_plain;f=mcproxy%2Fpatches%2F0003-uclibc-add-sourcefilter.patch;h=7c4e90c60c1822abe06807a8f065f2d91808b5d2;hb=e291dcb7c382306e2d38378fbcce5b7f12c0f648;hp=8e7832ca87c265f6c0073bc5f70a8c559b9b9b2a;hpb=0e39fefd7f18cf4616b0cda8663693083727d9c7;p=lede-routing%2F.git diff --git a/mcproxy/patches/0003-uclibc-add-sourcefilter.patch b/mcproxy/patches/0003-uclibc-add-sourcefilter.patch index 8e7832c..7c4e90c 100644 --- a/mcproxy/patches/0003-uclibc-add-sourcefilter.patch +++ b/mcproxy/patches/0003-uclibc-add-sourcefilter.patch @@ -1,17 +1,19 @@ --- a/mcproxy/src/utils/mc_socket.cpp +++ b/mcproxy/src/utils/mc_socket.cpp -@@ -37,6 +37,8 @@ +@@ -37,6 +37,10 @@ #include #include ++#ifdef __UCLIBC__ +#include "sourcefilter.cpp" ++#endif /* __UCLIBC__ */ + std::string ipAddrResolver(std::string ipAddr) { std::string str[][2] = { --- /dev/null +++ b/mcproxy/src/utils/sourcefilter.cpp -@@ -0,0 +1,168 @@ +@@ -0,0 +1,165 @@ +/* Get source filter. Linux version. + Copyright (C) 2004-2014 Free Software Foundation, Inc. + This file is part of the GNU C Library. @@ -41,9 +43,6 @@ +#include +#include + -+#define getsourcefilter getsourcefilter2 -+#define setsourcefilter setsourcefilter2 -+ +static const struct +{ + int sol; @@ -95,7 +94,7 @@ + + +int -+getsourcefilter2 (int s, uint32_t interface, const struct sockaddr *group, ++getsourcefilter (int s, uint32_t interface, const struct sockaddr *group, + socklen_t grouplen, uint32_t *fmode, uint32_t *numsrc, + struct sockaddr_storage *slist) +{ @@ -144,7 +143,7 @@ + + +int -+setsourcefilter2 (int s, uint32_t interface, const struct sockaddr *group, ++setsourcefilter (int s, uint32_t interface, const struct sockaddr *group, + socklen_t grouplen, uint32_t fmode, uint32_t numsrc, + const struct sockaddr_storage *slist) +{