Merge pull request #19843 from ANR2MERefork/apctl_getinfo

An attempt to fix Driver 76 multiplayer
This commit is contained in:
Henrik Rydgård 2025-01-10 09:23:35 +01:00 committed by GitHub
commit a986286532
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 1 additions and 4 deletions

View file

@ -871,9 +871,6 @@ int sceNetApctlTerm() {
static int sceNetApctlGetInfo(int code, u32 pInfoAddr) {
DEBUG_LOG(Log::sceNet, "UNTESTED %s(%i, %08x) at %08x", __FUNCTION__, code, pInfoAddr, currentMIPS->pc);
if (!netApctlInited)
return hleLogError(Log::sceNet, ERROR_NET_APCTL_NOT_IN_BSS, "apctl not in bss"); // Only have valid info after joining an AP and got an IP, right?
switch (code) {
case PSP_NET_APCTL_INFO_PROFILE_NAME:
if (!Memory::IsValidRange(pInfoAddr, APCTL_PROFILENAME_MAXLEN))

View file

@ -595,7 +595,7 @@ static int sceNetInetBind(int socket, u32 namePtr, int namelen) {
// Get Local IP Address
sockaddr_in sockAddr{};
getLocalIp(&sockAddr);
DEBUG_LOG(Log::sceNet, "Bind: Address Replacement = %s => %s", ip2str(saddr.in.sin_addr).c_str(), ip2str(sockAddr.sin_addr).c_str());
WARN_LOG(Log::sceNet, "Bind: Address Replacement = %s => %s", ip2str(saddr.in.sin_addr).c_str(), ip2str(sockAddr.sin_addr).c_str());
saddr.in.sin_addr.s_addr = sockAddr.sin_addr.s_addr;
}
// TODO: Make use Port Offset only for PPSSPP to PPSSPP communications (ie. IP addresses available in the group/friendlist), otherwise should be considered as Online Service thus should use the port as is.