Skip to content

Commit

Permalink
Fix: compiler throws an error when wanddr is not used
Browse files Browse the repository at this point in the history
  • Loading branch information
Monsterovich committed Oct 30, 2024
1 parent 0c7d8bd commit 3ea0d27
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/netplay/port_mapping_manager_impl_miniupnpc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,8 +132,8 @@ static PortMappingImpl_Miniupnpc::DiscoveryStatus upnp_discover(DiscoveryResults
return PortMappingImpl_Miniupnpc::DiscoveryStatus::UPNP_ERROR_DEVICE_NOT_FOUND;
}

char wanaddr[64] = {};
#if defined(MINIUPNPC_API_VERSION) && (MINIUPNPC_API_VERSION >= 18)
char wanaddr[64] = {};
int validIGDResult = UPNP_GetValidIGD(devlist, &output.urls, &output.data, output.lanaddr, sizeof(output.lanaddr), wanaddr, sizeof(wanaddr));
#else
int validIGDResult = UPNP_GetValidIGD(devlist, &output.urls, &output.data, output.lanaddr, sizeof(output.lanaddr));
Expand Down

0 comments on commit 3ea0d27

Please sign in to comment.