swt2c / rpms / megaglest

Forked from rpms/megaglest 5 years ago
Clone
Blob Blame History Raw
diff -up megaglest-3.12.0/source/shared_lib/sources/platform/posix/socket.cpp.orig megaglest-3.12.0/source/shared_lib/sources/platform/posix/socket.cpp
--- megaglest-3.12.0/source/shared_lib/sources/platform/posix/socket.cpp.orig	2016-06-24 08:00:27.521585488 -0300
+++ megaglest-3.12.0/source/shared_lib/sources/platform/posix/socket.cpp	2016-06-24 08:00:43.947586530 -0300
@@ -2631,7 +2631,9 @@ int UPNP_Tools::upnp_init(void *param) {
 				if(SystemFlags::VERBOSE_MODE_ENABLED) printf("UPnP device found: %s %s\n", dev->descURL, dev->st);
 
 				//printf("UPnP device found: [%s] [%s] lanaddr [%s]\n", dev->descURL, dev->st,lanaddr);
-#if (defined(MINIUPNPC_API_VERSION)  && MINIUPNPC_API_VERSION >= 9) || (!defined(MINIUPNPC_VERSION_PRE1_7) && !defined(MINIUPNPC_VERSION_PRE1_6))
+#if (defined(MINIUPNPC_API_VERSION)  && MINIUPNPC_API_VERSION >= 16)
+				char *descXML = (char *)miniwget_getaddr(dev->descURL, &descXMLsize, lanaddr, (sizeof(lanaddr) / sizeof(lanaddr[0])), 0, NULL);
+#elif (defined(MINIUPNPC_API_VERSION)  && MINIUPNPC_API_VERSION >= 9) || (!defined(MINIUPNPC_VERSION_PRE1_7) && !defined(MINIUPNPC_VERSION_PRE1_6))
 				char *descXML = (char *)miniwget_getaddr(dev->descURL, &descXMLsize, lanaddr, (sizeof(lanaddr) / sizeof(lanaddr[0])),0);
 #else
 				char *descXML = (char *)miniwget_getaddr(dev->descURL, &descXMLsize, lanaddr, (sizeof(lanaddr) / sizeof(lanaddr[0])));