[glib: 4/12] gio: compile GSocketAddress with AF_UNIX on all platforms




commit 37cab227fd2c8544516a5abb63566f37a0ecaba5
Author: Marc-André Lureau <marcandre lureau redhat com>
Date:   Wed Jan 19 00:03:31 2022 +0400

    gio: compile GSocketAddress with AF_UNIX on all platforms
    
    Signed-off-by: Marc-André Lureau <marcandre lureau redhat com>

 gio/gsocketaddress.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gio/gsocketaddress.c b/gio/gsocketaddress.c
index 2b7e83ccf..41dbe66ad 100644
--- a/gio/gsocketaddress.c
+++ b/gio/gsocketaddress.c
@@ -35,8 +35,10 @@
 #include "glibintl.h"
 #include "gioenumtypes.h"
 
-#ifdef G_OS_UNIX
 #include "gunixsocketaddress.h"
+
+#ifdef G_OS_WIN32
+#include "giowin32-afunix.h"
 #endif
 
 
@@ -265,7 +267,6 @@ g_socket_address_new_from_native (gpointer native,
       return sockaddr;
     }
 
-#ifdef G_OS_UNIX
   if (family == AF_UNIX)
     {
       struct sockaddr_un *addr = (struct sockaddr_un *) native;
@@ -299,7 +300,6 @@ g_socket_address_new_from_native (gpointer native,
       else
        return g_unix_socket_address_new (addr->sun_path);
     }
-#endif
 
   return g_native_socket_address_new (native, len);
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]