Age | Commit message (Collapse) | Author |
|
Signed-off-by: Uli Schlachter <psychon@znc.in>
|
|
Fix a redefinition problem which shows up when building for _WIN32 and
libXdmcp is installed, so HASXDMAUTH is enabled
It seems this is a special place in xcb as it uses other X11 library headers here
If HASXDMAUTH is defined, include the wrapped windows.h before any header which
includes it unwrapped, to avoid conflicts with types defined in X headers
We need to include config.h and check HASXDMAUTH to avoid an unconditional dependency
on x11proto headers
In file included from install/include/X11/Xdmcp.h:19:0,
from git/xcb/libxcb/src/xcb_auth.c:52:
install/include/X11/Xmd.h:120:14: error: conflicting types for 'INT32'
/usr/i686-pc-mingw32/sys-root/mingw/include/basetsd.h:54:13: note: previous declaration of 'INT32' was here
install/include/X11/Xmd.h:143:15: error: conflicting types for 'BOOL'
/usr/i686-pc-mingw32/sys-root/mingw/include/windef.h:234:17: note: previous declaration of 'BOOL' was here
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
This reverts commit 0e9246def562be97cc816f824f702233a826ec56.
This change caused build failures because <X11/Xdmcp.h> was never
included under any circumstance. This is because the check for
HASXDMAUTH was moved before the inclusion of config.h (via xcbint.h)
which defined it.
Found-by: Tinderbox
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
|
|
Fix a redefinition problem due to include order which shows up when
building for _WIN32 and libXdmcp is installed, so HASXDMAUTH is enabled
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Peter Harris <pharris@opentext.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
WIN32 does not have arpa/inet.h, so do not try to include it unless _WIN32 is
not defined
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Peter Harris <pharris@opentext.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
Some of these systems (eg. Interix on XP) are still in use.
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Peter Harris <pharris@opentext.com>
|
|
Variable new_sockname will leak and sockname will be double freed if
both of the cases shown below are true.
1. realloc succeeds and doesn't return the original pointer
2. calling socket_func fails
Signed-off-by: Rami Ylimäki <rami.ylimaki@vincit.fi>
Signed-off-by: Erkki Seppälä <erkki.seppala@vincit.fi>
Reviewed-by: Arnaud Fontaine <arnau@debian.org>
Signed-off-by: Peter Harris <pharris@opentext.com>
|
|
If the initial get_peer_sock_name(getpeername ...) succeeds, the
pointer to allocated memory is overwritten by the later call to
get_peer_sock_name(getsockname ...). Fix that up by freeing
the allocated memory before overwriting the pointer.
Signed-off-by: Nick Bowler <nbowler@draconx.ca>
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
Conflicts:
src/xcb_conn.c
src/xcb_util.c
Signed-off-by: Peter Harris <pharris@opentext.com>
|
|
There could be no upper limit on the length of a path according
to POSIX, therefore these macros may not be defined at all on
some systems (such as GNU Hurd).
Signed-off-by: Arnaud Fontaine <arnau@debian.org>
Reviewed-by: Peter Harris <pharris@opentext.com>
|
|
that.Replaced one instance ofWIN32 with _WIN32 in each xcb_in.c and xcb_conn.c
|
|
|
|
libxcb's 010e5661 (Fix XDM-AUTHORIZATION-1 (bug #14202)) mistakenly
inverted a few lines of code, making local socket authentication fail on
hpux and Hurd: when getpeername fails, sockname needs to be initialized
by getsockname before its address family can be checked.
Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
With this patch, we know use correctly the socket address or peer
address for authentication purpose.
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
That save us from a strlen().
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
Local socket connections currently do not work on hurd-i386 because
xcb_auth calls getpeername() on the client socket, but hurd-i386 does
not implement anything in that case (I actually wonder what reasonable
value could be returned). In such case the xcb code does not actually
need the peer name anyway.
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
Signed-off-by: Julien Danjou <julien@danjou.info>
|
|
|
|
|
|
|
|
Commit by Jamey Sharp and Josh Triplett.
|
|
Change xcb_connect to pass the display number to _xcb_get_auth_info, which
passes it to get_authptr. This allows get_authptr to stop hacking the display
number out of the sockaddrs of various address families, such as
port - X_TCP_PORT, or the number after the last X in the UNIX socket path. This
also removes a portability bug introduced during the IPv6 changes: relying on
'\0'-termination of the UNIX socket path in a sockaddr_un.
Commit by Jamey Sharp and Josh Triplett.
|
|
Support AF_INET6 in get_authptr, and refactor to use common code for IPv4 and
v4-mapped IPv6 addresses.
Commit by Jamey Sharp and Josh Triplett.
|
|
|
|
Rename API to follow a new naming convention:
* XCB_CONSTANTS_UPPERCASE_WITH_UNDERSCORES
* xcb_functions_lowercase_with_underscores
* xcb_types_lowercase_with_underscores_and_suffix_t
* expand all abbreviations like "req", "rep", and "iter"
Word boundaries for the names in the protocol descriptions fall:
* Wherever the protocol descriptions already have an underscore
* Between a lowercase letter and a subsequent uppercase letter
* Before the last uppercase letter in a string of uppercase letters followed
by a lowercase letter (such as in LSBFirst between LSB and First)
* Before and after a string of digits (with exceptions for sized types like
xcb_char2b_t and xcb_glx_float32_t to match the stdint.h convention)
Also fix up some particular naming issues:
* Rename shape_op and shape_kind to drop the "shape_" prefix, since otherwise
these types end up as xcb_shape_shape_{op,kind}_t.
* Remove leading underscores from enums in the GLX protocol description,
previously needed to ensure a word separator, but now redundant.
This renaming breaks code written for the previous API naming convention. The
scripts in XCB's tools directory will convert code written for the old API to
use the new API; they work well enough that we used them to convert the
non-program-generated code in XCB, and when run on the old program-generated
code, they almost exactly reproduce the new program-generated code (modulo
whitespace and bugs in the old code generator).
Authors: Vincent Torri, Thomas Hunger, Josh Triplett
|
|
Fix xcb_auth to use one of the new enumerations.
|
|
workaround: FIXME!
|
|
(Still including X.h until defs are moved to xproto.xml
and xcb-util and xcb-demo are fixed to use them.)
|
|
|
|
bug #6106.
|
|
This may fix itermittant connect failures.
|
|
|