Ignore generated xinerama files.
[free-sw/xcb/libxcb] / src / xcb_auth.c
index 46c85fd..4c9f7d6 100644 (file)
 #include <unistd.h>
 #include <stdlib.h>
 
-/* FIXME: for the moment Xdmcp.h must be included before xcb.h because
- * it includes Xmd.h, but config.h (normally included from xcbint.h
- * which must be included after xcb.h) must be included before Xdmcp.h.
- * Ow. */
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
+#include "xcb.h"
+#include "xcbint.h"
 
 #ifdef HASXDMAUTH
 #include <X11/Xdmcp.h>
 #endif
 
-#include "xcb.h"
-#include "xcbint.h"
-
 enum auth_protos {
 #ifdef HASXDMAUTH
     AUTH_XA1,
@@ -105,7 +97,7 @@ static Xauth *get_authptr(struct sockaddr *sockname, unsigned int socknamelen)
             addr = (char *) &si->sin_addr;
             addrlen = 4;
             if (ntohl(si->sin_addr.s_addr) != 0x7f000001)
-                family = XCBFamilyInternet;
+                family = XCB_FAMILY_INTERNET;
             snprintf(dispbuf, sizeof(dispbuf), "%d", ntohs(si->sin_port) - X_TCP_PORT);
             display = dispbuf;
         }
@@ -158,7 +150,7 @@ static void do_append(char *buf, int *idxp, void *val, size_t valsize) {
 }
 #endif
      
-static int compute_auth(XCBAuthInfo *info, Xauth *authptr, struct sockaddr *sockname)
+static int compute_auth(xcb_auth_info_t *info, Xauth *authptr, struct sockaddr *sockname)
 {
     if (authname_match(AUTH_MC1, authptr->name, authptr->name_length)) {
         info->datalen = memdup(&info->data, authptr->data, authptr->data_length);
@@ -216,7 +208,7 @@ static int compute_auth(XCBAuthInfo *info, Xauth *authptr, struct sockaddr *sock
     return 0;   /* Unknown authorization type */
 }
 
-int _xcb_get_auth_info(int fd, XCBAuthInfo *info)
+int _xcb_get_auth_info(int fd, xcb_auth_info_t *info)
 {
     /* code adapted from Xlib/ConnDis.c, xtrans/Xtranssocket.c,
        xtrans/Xtransutils.c */