mirror of
https://github.com/godotengine/godot.git
synced 2026-01-03 18:11:19 +03:00
miniupnpc: Update to 2.2.8 (new major 18)
Keep support for major 17 by using a version check for the changed API. Fixes #93907.
This commit is contained in:
@@ -131,7 +131,11 @@ void UPNP::parse_igd(Ref<UPNPDevice> dev, UPNPDev *devlist) {
|
||||
GetUPNPUrls(&urls, &data, dev->get_description_url().utf8().get_data(), 0);
|
||||
|
||||
char addr[16];
|
||||
#if MINIUPNPC_API_VERSION >= 18
|
||||
int i = UPNP_GetValidIGD(devlist, &urls, &data, (char *)&addr, 16, nullptr, 0);
|
||||
#else
|
||||
int i = UPNP_GetValidIGD(devlist, &urls, &data, (char *)&addr, 16);
|
||||
#endif
|
||||
|
||||
if (i != 1) {
|
||||
FreeUPNPUrls(&urls);
|
||||
|
||||
Reference in New Issue
Block a user