diff options
author | Jeff Garzik <jgarzik@exmulti.com> | 2011-08-04 11:40:44 -0700 |
---|---|---|
committer | Jeff Garzik <jgarzik@exmulti.com> | 2011-08-04 11:40:44 -0700 |
commit | 95699e1730e80ecaea8f617ef3ea231fdcde2f44 (patch) | |
tree | 44604e6d8e65db5daad70fcaf13ba741460c3624 | |
parent | 32de8cd062df3df5c34922d262484b934024eb06 (diff) | |
parent | 15656981697f3421043a3d371bb887f036a32cf0 (diff) |
Merge pull request #446 from WakiMiko/upnp-desc
Identify as "Bitcoin + version number" when mapping UPnP port
-rw-r--r-- | src/net.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/net.cpp b/src/net.cpp index 2a90f6d0cc..d697788213 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -1092,13 +1092,14 @@ void ThreadMapPort2(void* parg) { char intClient[16]; char intPort[6]; + string strDesc = "Bitcoin " + FormatFullVersion(); #ifndef __WXMSW__ r = UPNP_AddPortMapping(urls.controlURL, data.first.servicetype, - port, port, lanaddr, 0, "TCP", 0); + port, port, lanaddr, strDesc.c_str(), "TCP", 0); #else r = UPNP_AddPortMapping(urls.controlURL, data.first.servicetype, - port, port, lanaddr, 0, "TCP", 0, "0"); + port, port, lanaddr, strDesc.c_str(), "TCP", 0, "0"); #endif if(r!=UPNPCOMMAND_SUCCESS) printf("AddPortMapping(%s, %s, %s) failed with code %d (%s)\n", |