summaryrefslogtreecommitdiff
path: root/network/dobbscoin/miniupnpc-1.9-api.patch
blob: 2fe88bac4bcdf68dd76790291a107483ac1317b7 (plain)
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
From 984e204d7c60f0d0c5cc7d1c3a5daefcd7433f6e Mon Sep 17 00:00:00 2001
From: acerix <dylan@psilly.com>
Date: Wed, 7 Oct 2015 20:33:08 -0400
Subject: [PATCH] apply bitcoin patch for miniupnpc 1.9

---
 src/net.cpp | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/src/net.cpp b/src/net.cpp
index 279ee4d..f7ea000 100644
--- a/src/net.cpp
+++ b/src/net.cpp
@@ -1109,10 +1109,14 @@ void ThreadMapPort()
 #ifndef UPNPDISCOVER_SUCCESS
     /* miniupnpc 1.5 */
     devlist = upnpDiscover(2000, multicastif, minissdpdpath, 0);
-#else
+#elif MINIUPNPC_API_VERSION < 14
     /* miniupnpc 1.6 */
     int error = 0;
     devlist = upnpDiscover(2000, multicastif, minissdpdpath, 0, 0, &error);
+#else
+    /* miniupnpc 1.9.20150730 */
+    int error = 0;
+    devlist = upnpDiscover(2000, multicastif, minissdpdpath, 0, 0, 2, &error);
 #endif
 
     struct UPNPUrls urls;