diff options
author | Riccardo Spagni <ric@spagni.net> | 2014-10-04 07:46:49 +0200 |
---|---|---|
committer | Riccardo Spagni <ric@spagni.net> | 2014-10-04 07:47:04 +0200 |
commit | faca0db9c596413cd2acd124abf08f2ef6c3c612 (patch) | |
tree | 8e9011253f0a8ebb280405899637cb2b25fb0b15 /external/miniupnpc/miniupnpc.c | |
parent | Merge pull request #165 (diff) | |
parent | fixed checkpointing bug (diff) | |
download | monero-faca0db9c596413cd2acd124abf08f2ef6c3c612.tar.xz |
Merge pull request #169
1160505 fixed checkpointing bug (Riccardo Spagni)
c4d6658 quick hacky fix for broken TXT reads (Riccardo Spagni)
2322a94 cleaned up OpenAlias messages in simplewallet (Riccardo Spagni)
1663089 MoneroPulse log wording tweaks (Riccardo Spagni)
1d515b8 boost 1.56 kindly (and officially) patched in msys2 by Alexey Pavlov (Riccardo Spagni)
e3d2400 forgot to add connection context to log line (Riccardo Spagni)
6f7ed13 moved checkpoint log level (Riccardo Spagni)
3e644c2 moved file checkpointing log output to log1 (Riccardo Spagni)
0e1b7c9 moved non-critical p2p errors to l2 (Riccardo Spagni)
a3332e7 remove dangling upnp port mappings, updated miniupnpc (Riccardo Spagni)
6b9a7fc fixed unbound static lib on mingw as libunbound.dll.a (Riccardo Spagni)
bba217a remove pthreads, successfully tested on gcc 4.9.1 without pthreads (Riccardo Spagni)
18281f4 remove dangling upnp port mappings, updated miniupnpc (Riccardo Spagni)
9130e41 fixed unbound static lib on mingw as libunbound.dll.a (Riccardo Spagni)
8c37823 remove pthreads, successfully tested on gcc 4.9.1 without pthreads (Riccardo Spagni)
Diffstat (limited to 'external/miniupnpc/miniupnpc.c')
-rw-r--r--[-rwxr-xr-x] | external/miniupnpc/miniupnpc.c | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/external/miniupnpc/miniupnpc.c b/external/miniupnpc/miniupnpc.c index f661c2e6f..1da230f52 100755..100644 --- a/external/miniupnpc/miniupnpc.c +++ b/external/miniupnpc/miniupnpc.c @@ -1,4 +1,4 @@ -/* $Id: miniupnpc.c,v 1.117 2014/01/31 14:19:13 nanard Exp $ */ +/* $Id: miniupnpc.c,v 1.116 2014/01/31 14:09:03 nanard Exp $ */ /* Project : miniupnp * Web : http://miniupnp.free.fr/ * Author : Thomas BERNARD @@ -6,7 +6,7 @@ * This software is subjet to the conditions detailed in the * provided LICENSE file. */ #define __EXTENSIONS__ 1 -#if !defined(MACOSX) && !defined(__sun) +#if !defined(__APPLE__) && !defined(__sun) #if !defined(_XOPEN_SOURCE) && !defined(__OpenBSD__) && !defined(__NetBSD__) #ifndef __cplusplus #define _XOPEN_SOURCE 600 @@ -17,7 +17,7 @@ #endif #endif -#if !defined(__DragonFly__) && !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(MACOSX) && !defined(_WIN32) && !defined(__CYGWIN__) && !defined(__sun) +#if !defined(__DragonFly__) && !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(__APPLE__) && !defined(_WIN32) && !defined(__CYGWIN__) && !defined(__sun) && !defined(__GNU__) && !defined(__FreeBSD_kernel__) #define HAS_IP_MREQN #endif @@ -70,6 +70,9 @@ /* Amiga OS specific stuff */ #define TIMEVAL struct timeval #endif +#ifdef __GNU__ +#define MAXHOSTNAMELEN 64 +#endif #if defined(HAS_IP_MREQN) && defined(NEED_STRUCT_IP_MREQN) @@ -106,7 +109,7 @@ struct ip_mreqn #define SERVICEPREFIX2 'u' /* root description parsing */ -LIBSPEC void parserootdesc(const char * buffer, int bufsize, struct IGDdatas * data) +MINIUPNP_LIBSPEC void parserootdesc(const char * buffer, int bufsize, struct IGDdatas * data) { struct xmlparser parser; /* xmlparser object */ @@ -335,7 +338,7 @@ parseMSEARCHReply(const char * reply, int size, * no devices was found. * It is up to the caller to free the chained list * delay is in millisecond (poll) */ -LIBSPEC struct UPNPDev * +MINIUPNP_LIBSPEC struct UPNPDev * upnpDiscover(int delay, const char * multicastif, const char * minissdpdsock, int sameport, int ipv6, @@ -718,7 +721,7 @@ upnpDiscover(int delay, const char * multicastif, /* freeUPNPDevlist() should be used to * free the chained list returned by upnpDiscover() */ -LIBSPEC void freeUPNPDevlist(struct UPNPDev * devlist) +MINIUPNP_LIBSPEC void freeUPNPDevlist(struct UPNPDev * devlist) { struct UPNPDev * next; while(devlist) @@ -754,7 +757,7 @@ url_cpy_or_cat(char * dst, const char * src, int n) /* Prepare the Urls for usage... */ -LIBSPEC void +MINIUPNP_LIBSPEC void GetUPNPUrls(struct UPNPUrls * urls, struct IGDdatas * data, const char * descURL, unsigned int scope_id) { @@ -844,7 +847,7 @@ GetUPNPUrls(struct UPNPUrls * urls, struct IGDdatas * data, #endif } -LIBSPEC void +MINIUPNP_LIBSPEC void FreeUPNPUrls(struct UPNPUrls * urls) { if(!urls) @@ -891,7 +894,7 @@ UPNPIGD_IsConnected(struct UPNPUrls * urls, struct IGDdatas * data) * passed as parameters are set. Donc forget to call FreeUPNPUrls(urls) to * free allocated memory. */ -LIBSPEC int +MINIUPNP_LIBSPEC int UPNP_GetValidIGD(struct UPNPDev * devlist, struct UPNPUrls * urls, struct IGDdatas * data, |