Kaynağa Gözat

[Hotfix] sockets: Resolve empty port requests to 0 again (#5459)

TSRBerry 2 yıl önce
ebeveyn
işleme
732714349e

+ 1 - 1
src/Ryujinx.HLE/HOS/Services/Sockets/Sfdnsres/IResolver.cs

@@ -586,7 +586,7 @@ namespace Ryujinx.HLE.HOS.Services.Sockets.Sfdnsres
 
 
             if (hostEntry != null)
             if (hostEntry != null)
             {
             {
-                if (int.TryParse(service, out int port))
+                if (int.TryParse(service, out int port) || string.IsNullOrEmpty(service))
                 {
                 {
                     errno = GaiError.Success;
                     errno = GaiError.Success;
                     serializedSize = SerializeAddrInfos(context, responseBufferPosition, responseBufferSize, hostEntry, port);
                     serializedSize = SerializeAddrInfos(context, responseBufferPosition, responseBufferSize, hostEntry, port);