Browse Source

fphttpclient - only handle Unix in conditional compilation for UnixSocketPath feature

Ionut Stoica 3 years ago
parent
commit
bef4da339a
1 changed files with 2 additions and 4 deletions
  1. 2 4
      packages/fcl-web/src/base/fphttpclient.pp

+ 2 - 4
packages/fcl-web/src/base/fphttpclient.pp

@@ -684,8 +684,7 @@ begin
     FSocket:=TUnixSocket.Create(UnixSocketPath)
   else
     FSocket:=TInetSocket.Create(AHost,APort,G);
-  {$endif}
-  {$ifdef windows}
+  {$else}
     FSocket:=TInetSocket.Create(AHost,APort,G);
   {$endif}  
   try
@@ -696,8 +695,7 @@ begin
     {$ifdef Unix}
     if not IsUnixSocketConnection then
       (FSocket as TInetSocket).Connect;
-    {$endif}
-    {$ifdef windows}
+    {$else}
       (FSocket as TInetSocket).Connect;
     {$endif}
   except