commit a0e938baa3ab51c8f42d62522da15d1fd56d7d1c
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Fri Jun 27 10:57:48 2014 +1000

    Bump version to 1.15.2
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>

commit 2abbf56493bb8636ae1ef6de2cbb412ac79c717f
Author: Steven McDonald <steven@steven-mcdonald.id.au>
Date:   Sun May 18 13:42:08 2014 +0200

    Xi: block SIGIOs while copying device classes around
    
    I've been seeing sporadic (anywhere from once every few days to 3-4
    times a day) crashes and freezes in X. The problematic behaviour isn't
    always the same, but I chose a particular incident to debug, and found
    that X was segfaulting in updateMotionHistory, on line 575 of
    dix/getevents.c.
    
    After some further investigation, I found that the bug was being
    triggered when a SIGIO was received in DeepCopyPointerClasses, between
    the AllocValuatorClass call (line 540) and updating the to->valuator
    pointer (line 545). AllocValuatorClass calls realloc() on to->valuator,
    so between these lines, it's not guaranteed to point to allocated
    memory.
    
    It seems the SIGIO handler is calling updateMotionHistory, which is
    reading the memory pointed to by to->valuator and getting a wrong value
    for last_motion, which updates buff to point to wildly the wrong place
    and thus generates a segfault when a memcpy() is done into buff.
    
    I am attaching a patch which I've been running on that machine for the
    past three days, and haven't yet observed any more crashing or freezing
    behaviour. The patch simply calls OsBlockSIGIO while
    DeepCopyDeviceClasses is in progress, as the state of the X server's
    device data structures is not guaranteed to be in a consistent state
    during that time.
    
    Debian bug#744303 <https://bugs.debian.org/744303>
    
    Signed-off-by: Julien Cristau <jcristau@debian.org>
    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    (cherry picked from commit d7a2df0a7499864cb005b098b79c1bdf884f6600)

commit 2ceb44827f86d9f5f995448c3cf603ee9459fef3
Author: Robert Ancell <robert.ancell@canonical.com>
Date:   Thu May 22 10:43:52 2014 +1200

    Fix overflow checking extension versions
    
    The easiest way to check for the version of an extension is to send the maximum
    possible version numbers in the QueryVersion request. The X server overflows on
    these as it assumes you will send a reasonable version number.
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    Reviewed-by: Keith Packard <keithp@keithp.com>
    (cherry picked from commit 548fc937b22d4dfe7f96e0bd77522261603a2c2f)

commit 416ea95d8018875ed77a46634e5ab4d8b6e94dec
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Sat May 24 20:05:53 2014 +1000

    man: drop specific mention of DontZap in -retro (#71113)
    
    DontZap off is the default anyway, don't mention it specifically to avoid
    confusion
    
    X.Org Bug 71113 <http://bugs.freedesktop.org/show_bug.cgi?id=71113>
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    (cherry picked from commit cfaf2abbac3f01e57d00845d8908bf01559263f9)

commit 18f3471a05a7fba19713c788ed92e5e2ea7a4452
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Sat May 24 20:02:56 2014 +1000

    xfree86: fix wrong DontZap documentation (#71113)
    
    X.Org Bug 71113 <http://bugs.freedesktop.org/show_bug.cgi?id=71113>
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    (cherry picked from commit e48a132b6d187f355abd7021be47edde972e7091)

commit 57a042682029d009094a59914d6044b57ebf209b
Author: Matt Dew <marcoz@osource.org>
Date:   Sun Jun 22 22:11:48 2014 -0600

    Bump version # to 1.15.1.901

commit 268eb961c9c58fc7cc26e514661b5f8304c1c08f
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sat May 31 17:45:02 2014 -0700

    XQuartz: Update logic to account for title bar on every display in Mavericks
    
    <rdar://problem/14205847>
    http://xquartz.macosforge.org/trac/ticket/832
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit 1c10b37380d228b35db8a8616a6312ac54f5e59b)

commit 624461797e05da711212329a5c7677df2544fb21
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sat May 31 17:22:51 2014 -0700

    XQuartz: Dead code removal (ENABLE_DEBUG_LOG)
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit ad0ff649c68b18c4b95b078c2d1d1e7de71a7c6f)

commit 77ab9ca61717054b1c8c09594b01f04c3f4681f3
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sat May 31 13:04:43 2014 -0700

    XQuartz: Bump to 2.7.7
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit e281288d5afedb154f52c31f70a350a013ecfb06)

commit 6e31a3e4b51b89180ddbcdb40308e4192a64301f
Author: Peter Harris <pharris@opentext.com>
Date:   Fri Apr 11 17:44:59 2014 -0400

    fb: Fix origin of source picture in fbGlyphs
    
    If a source picture doesn't repeat and a mask format is specified, the
    incorrect calulation of the origin of the glyphs caused the glyphs to
    not be drawn at all.
    
    Noticed when running gtk-demo from RHEL 6.5 and selecting "Rotated
    Text".
    
    Signed-off-by: Peter Harris <pharris@opentext.com>
    Reviewed-by: Keith Packard <keithp@keithp.com>
    Signed-off-by: Keith Packard <keithp@keithp.com>
    
    /* Test for this bug
    
    cc -std=c99 -o glyph glyph.c `pkg-config --cflags --libs xcb-render`
    
    */
    
    // 16 x 16 pictfmt_a8 "glyph"
    static const char glyph[] = {
        0xff, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xff,
        0, 0xff, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xff, 0,
        0, 0, 0xff, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xff, 0, 0,
        0, 0, 0, 0xff, 0, 0, 0, 0, 0, 0, 0, 0, 0xff, 0, 0, 0,
        0, 0, 0, 0, 0xff, 0, 0, 0, 0, 0, 0, 0xff, 0, 0, 0, 0,
        0, 0, 0, 0, 0, 0xff, 0, 0, 0, 0, 0xff, 0, 0, 0, 0, 0,
        0, 0, 0, 0, 0, 0, 0xff, 0, 0, 0xff, 0, 0, 0, 0, 0, 0,
        0, 0, 0, 0, 0, 0, 0, 0xff, 0xff, 0, 0, 0, 0, 0, 0, 0,
        0, 0, 0, 0, 0, 0, 0, 0xff, 0xff, 0, 0, 0, 0, 0, 0, 0,
        0, 0, 0, 0, 0, 0, 0xff, 0, 0, 0xff, 0, 0, 0, 0, 0, 0,
        0, 0, 0, 0, 0, 0xff, 0, 0, 0, 0, 0xff, 0, 0, 0, 0, 0,
        0, 0, 0, 0, 0xff, 0, 0, 0, 0, 0, 0, 0xff, 0, 0, 0, 0,
        0, 0, 0, 0xff, 0, 0, 0, 0, 0, 0, 0, 0, 0xff, 0, 0, 0,
        0, 0, 0xff, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xff, 0, 0,
        0, 0xff, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xff, 0,
        0xff, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xff,
    };
    
    static struct {
        uint8_t len;
        uint8_t pad[3];
        uint16_t deltax, deltay;
        uint8_t glyph;
        uint8_t pad2[3];
    } elt = { len:1, glyph:1, deltax:WIN_SIZE/2 - GLYPH_SIZE/2, deltay:WIN_SIZE/2 - GLYPH_SIZE/2 };
    
    int main(int argc, char *argv[])
    {
        int screen;
        xcb_connection_t *c = xcb_connect(NULL, &screen);
        if (!c || xcb_connection_has_error(c)) {
    	fprintf(stderr, "Cannot open default display \"%s\"\n", getenv("DISPLAY"));
    	return EXIT_FAILURE;
        }
    
        // Find root window and depth
        const xcb_setup_t *setup = xcb_get_setup(c);
        if (screen >= setup->roots_len)
    	screen = 0;
        xcb_screen_iterator_t si = xcb_setup_roots_iterator(setup);
        for (int i=0; i < screen; i++)
    	xcb_screen_next(&si);
        xcb_window_t root = si.data->root;
        uint8_t depth = si.data->root_depth;
        xcb_visualid_t visual = si.data->root_visual;
    
        // Find picture formats
        xcb_render_query_pict_formats_reply_t *qpf;
        qpf = xcb_render_query_pict_formats_reply(c, xcb_render_query_pict_formats(c), NULL);
        if (!qpf) {
    	fprintf(stderr, "Cannot query RENDER picture formats\n");
    	return EXIT_FAILURE;
        }
        xcb_render_pictformat_t fmt_a8 = 0;
        xcb_render_pictforminfo_iterator_t pfi =
            xcb_render_query_pict_formats_formats_iterator(qpf);
        for (int i = 0; i < xcb_render_query_pict_formats_formats_length(qpf); i++) {
    
            if (pfi.data->depth == 8 &&
                    pfi.data->type == XCB_RENDER_PICT_TYPE_DIRECT &&
                    pfi.data->direct.alpha_mask == 0xFF) {
                fmt_a8 = pfi.data->id;
                break;
            }
            xcb_render_pictforminfo_next(&pfi);
        }
        if (!fmt_a8) {
    	fprintf(stderr, "Cannot find a8 RENDER picture format\n");
    	return EXIT_FAILURE;
        }
    
        xcb_render_pictformat_t fmt_visual = 0;
        xcb_render_pictscreen_iterator_t psi =
            xcb_render_query_pict_formats_screens_iterator(qpf);
        for (int i = 0; i < xcb_render_query_pict_formats_screens_length(qpf); i++) {
            xcb_render_pictdepth_iterator_t pdi =
                xcb_render_pictscreen_depths_iterator(psi.data);
            for (int j = 0; i < xcb_render_pictscreen_depths_length(psi.data); i++) {
                xcb_render_pictvisual_iterator_t pvi =
                    xcb_render_pictdepth_visuals_iterator(pdi.data);
                for (int k = 0; k < xcb_render_pictdepth_visuals_length(pdi.data); i++) {
                    if (pvi.data->visual == visual) {
                        fmt_visual = pvi.data->format;
                        goto found_visual;
                    }
                    xcb_render_pictvisual_next(&pvi);
                }
                xcb_render_pictdepth_next(&pdi);
            }
            xcb_render_pictscreen_next(&psi);
        }
    found_visual:
        if (!fmt_visual) {
    	fprintf(stderr, "Cannot find visual RENDER picture format\n");
    	return EXIT_FAILURE;
        }
    
        xcb_render_glyphset_t glyphset = xcb_generate_id(c);
        xcb_render_create_glyph_set(c, glyphset, fmt_a8);
        uint32_t glyph_ids[] = {1};
        xcb_render_add_glyphs(c, glyphset, 1, glyph_ids,
                &(xcb_render_glyphinfo_t){width:GLYPH_SIZE, height:GLYPH_SIZE}, sizeof(glyph), glyph);
    
        // Create window, pixmap, and gc
        xcb_window_t window = xcb_generate_id(c);
        uint32_t list[] = { si.data->black_pixel, XCB_EVENT_MASK_EXPOSURE };
        xcb_create_window(c, XCB_COPY_FROM_PARENT, window, root, 0, 0, WIN_SIZE, WIN_SIZE,
    	    0, XCB_WINDOW_CLASS_INPUT_OUTPUT, XCB_COPY_FROM_PARENT,
    	    XCB_CW_BACK_PIXEL | XCB_CW_EVENT_MASK, list);
        xcb_map_window(c, window);
        xcb_render_picture_t winpic = xcb_generate_id(c);
        xcb_render_create_picture(c, winpic, window, fmt_visual, 0, NULL);
    
        xcb_pixmap_t pixmap = xcb_generate_id(c);
        xcb_create_pixmap(c, depth, pixmap, window, GLYPH_SIZE, GLYPH_SIZE);
        xcb_render_picture_t pixpic = xcb_generate_id(c);
        xcb_render_create_picture(c, pixpic, pixmap, fmt_visual, 0, NULL);
        xcb_render_fill_rectangles(c, XCB_RENDER_PICT_OP_SRC, pixpic,
                (xcb_render_color_t){green:0xFFFF, alpha:0xFFFF}, 1,
                &(xcb_rectangle_t){width:GLYPH_SIZE, height:GLYPH_SIZE} );
    
        xcb_flush(c);
        for (xcb_generic_event_t *ev = xcb_wait_for_event(c); ev; ev = xcb_wait_for_event(c)) {
    	int type = ev->response_type;
    	free(ev);
    	if (type == XCB_EXPOSE) {
                xcb_clear_area(c, 0, window, 0, 0, 0, 0);
                xcb_render_composite_glyphs_8(c, XCB_RENDER_PICT_OP_SRC, pixpic, winpic, fmt_a8,
                        glyphset, 0, 0, sizeof(elt), (uint8_t *)&elt);
                xcb_flush(c);
            }
        }
    
        return EXIT_SUCCESS;
    }
    
    (cherry picked from commit 983e30361f49a67252d0b5d82630e70724d69dbf)

commit 7b3aa3f0be8d1334dbf23bd04258a8856a4329c7
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sun Apr 6 05:32:00 2014 -0700

    XQuartz: Ensure we wait for the server thread to terminate
    
    AKA: XQuartz 2.7.5 doesn't delete its /tmp/.X$d-lock
    
    http://xquartz.macosforge.org/trac/ticket/823
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>

commit 9182af8a09c326bb4b01d3645fb2936e93f02242
Author: Matt Dew <marcoz@osource.org>
Date:   Sun Apr 13 20:55:40 2014 -0600

    Bump version to 1.15.1

commit eec04d76a39a7334de4e00ef9f0f6e44c92b3d91
Author: Eric Anholt <eric@anholt.net>
Date:   Thu Mar 6 18:50:07 2014 -0800

    glx: Clear new FBConfig attributes to 0 by default.
    
    The visualSelectGroup wasn't getting set (since our DRI drivers don't
    use it), and and since it's the top priority in the sort order, you
    got random sorting of your visuals unless malloc really returned you
    new memory.  This manifested as Xephyr -glamor rendering to a
    multisampled window on my system, which as you might guess was
    slightly lower performance than expected.
    
    Signed-off-by: Eric Anholt <eric@anholt.net>
    Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>

commit d6268c25a8d33241d817977a84f127f8ef0cb9ee
Author: Julien Cristau <jcristau@debian.org>
Date:   Wed Mar 26 23:24:20 2014 +0100

    Xephyr: restore initial window resize lost in xcb conversion
    
    The XResizeWindow call wasn't replaced by the xcb equivalent, so we
    were no longer setting the initial window size, only wm size hints.
    
    Regression from commit a2b73da "Xephyr: start converting hostx.c over to
    xcb"
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=74849
    
    Signed-off-by: Julien Cristau <jcristau@debian.org>
    Reported-by: Laércio de Sousa <lbsousajr@gmail.com>
    Tested-by: Jon TURNEY <jon.turney@dronecode.org.uk>
    Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
    Signed-off-by: Keith Packard <keithp@keithp.com>

commit 300458fb8ad0a7957e941cd65f47d204c7886e22
Author: Matt Dew <marcoz@osource.org>
Date:   Fri Mar 21 23:49:41 2014 -0600

    Bump bersion to 1.15.0.901

commit c971864565eb114e4b34f17b0d2244e8e6e1e005
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Wed Feb 26 07:54:56 2014 +1000

    config: search for PnPID on all parents (#75513)
    
    The PnPID for a device may not be on the immediate parent, so search up the
    device tree until we find one.
    
    X.Org Bug 75513 <http://bugs.freedesktop.org/show_bug.cgi?id=75513>
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    Tested-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
    (cherry picked from commit 795066477ee81b5b82e490eac8bed6b656d01f17)

commit 2cbbe80efc485d2d05b06efe1e2e01f81f3e06f6
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Thu Feb 20 13:18:05 2014 +1000

    Xi: check for invalid modifiers for XI2 passive grabs
    
    The other values are checked correctly, but if a modifier was outside the
    allowed range, it would go unnoticed and cause a out-of-bounds read error for
    any mask equal or larger than 256. The DetailRec where we store the grab masks
    is only sized to 8 * sizeof(Mask).
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
    (cherry picked from commit 0f10cfd4b903d4db293ec47c8a9a0d8b33965803)

commit b3656c0b52d57333c64f932676a237d0f3a97f36
Author: Mark Kettenis <kettenis@openbsd.org>
Date:   Sun Dec 15 14:31:10 2013 +0100

    sync: Avoid ridiculously long timeouts
    
    On OpenBSD, passing a timeout longer than 100000000 seconds to select(2) will
    make it fail with EINVAL.  As this is original 4.4BSD behaviour it is not
    inconceivable that other systems suffer from the same problem.  And Linux,
    though not suffering from any 4.4BSD heritage, briefly did something similar:
    
    <https://lkml.org/lkml/2012/8/31/263>
    
    So avoid calling AdjustWaitForDelay() instead of setting the timeout to
    (effectively) ULONG_MAX milliseconds.
    
    Signed-off-by: Mark Kettenis <kettenis@openbsd.org>
    Reviewed-by: Matthieu Herrb <matthieu@herrb.eu>
    (cherry picked from commit ddeca927498c9df3b5e62c7bf05e31e2a3aeaa52)

commit b332cd20ee14049606e3656490d13a8efa6b23ee
Merge: f41ab8c 5e0432f
Author: Matt Dew <marcoz@osource.org>
Date:   Thu Mar 6 22:03:03 2014 -0700

    Merge branch 'server-1.15-branch' of git://people.freedesktop.org/~jeremyhu/xserver into server-1.15-branch

commit f41ab8c60780ea8f87354e536e5b73cb23878eb7
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Fri Jan 24 18:32:54 2014 +1000

    dix: prevent a driver from initializing or submitting buttons > MAX_BUTTONS
    
    The server internally relies on arrays with a MAX_BUTTONS maximum size (which
    is the max the core protocol can transport). Make sure a driver adheres to
    that.
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    Reviewed-by: Daniel Stone <daniel@fooishbar.org>
    (cherry picked from commit 87ca80a7196949597113225405f3e4ee03bbee13)

commit 4447d71b9a74afe91aaf4cc01eae12a44ef09306
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date:   Tue Jan 28 20:27:51 2014 -0800

    xf86DeleteScreen: move check for NULL pScrn before first dereference
    
    Flagged by cppcheck 1.62:
    [hw/xfree86/common/xf86Helper.c:220] -> [hw/xfree86/common/xf86Helper.c:231]:
     (warning) Possible null pointer dereference: pScrn - otherwise it is
     redundant to check it against null.
    
    Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
    Signed-off-by: Keith Packard <keithp@keithp.com>
    (cherry picked from commit c1ac89c793614797e08d3d8e7fc9ba55be899130)

commit 2ac840a14958fe74170518ee2c3a6b2dd88b20bd
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date:   Tue Jan 28 20:27:50 2014 -0800

    On realloc failure, free font_path_string instead of leaking it
    
    Flagged by cppcheck 1.62:
    [dix/dixfonts.c:1792]: (error) Common realloc mistake:
     'font_path_string' nulled but not freed upon failure
    
    Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
    Signed-off-by: Keith Packard <keithp@keithp.com>
    (cherry picked from commit e6733ae91b7be52930f22a87de15fa05819ef948)

commit 157cc02fc13c998bba70e1652907972015e15e8e
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date:   Fri Jan 24 23:42:49 2014 -0800

    Check for calloc() failure in add_master()
    
    Reported-by: Ilja Van Sprundel <ivansprundel@ioactive.com>
    Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    (cherry picked from commit 9fc19168e7ca6308275bf8769d1ccb982f88465b)

commit f11c5938d732af717aeebbbf3b356138f3411bb7
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Fri Jan 24 16:51:02 2014 +1000

    Xi: fix modifier offset in XIPassiveGrab swapping function
    
    The request is followed by mask_len 4-byte units, then followed by the actual
    modifiers.
    
    Also fix up the swapping test, which had the same issue.
    
    Reported-by: Alan Coopersmith <alan.coopersmith@oracle.com>
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
    (cherry picked from commit 76b3be75b62657e346731444736f7e4d200beb5b)
    
    Conflicts:
    	test/xi2/protocol-xipassivegrabdevice.c

commit 345b7ead1dd262020e10b4aeb71044d46d16e134
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Mon Jan 13 17:00:23 2014 +1000

    os: restrict display names to digits
    
    We call atoi() on the server's display to get the socket but otherwise use the
    unmodified display for log file name, xkb paths, etc. This results in
    Xorg :banana being the equivalent of Xorg :0, except for the log files being
    in /var/log/Xorg.banana.log. I'm not sure there's a good use-case for this
    behaviour.
    
    Check the display for something that looks reasonable, i.e. digits only, but
    do allow for :0.0 (i.e. digits, followed by a period, followed by one or two
    digits).
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    Reviewed-by: Keith Packard <keithp@keithp.com>
    (cherry picked from commit 71baa466b1f6b02fe503f9a3089b7b9d61aa0f80)

commit 940d6a8e9d3544696654d5e68c615ab887f81945
Author: Carlos Garnacho <carlosg@gnome.org>
Date:   Thu Jan 2 21:33:30 2014 +0100

    Xi: Ensure DeviceChanged is emitted after grabs are deactivated
    
    When a grab on a slave device is deactivated, the master device must
    be checked, just in case there were events from other devices while
    the slave device was stolen away by the passive grab. This may
    introduce misbehaviors on mismatching valuators and device features
    later on UpdateDeviceState().
    
    Signed-off-by: Carlos Garnacho <carlosg@gnome.org>
    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    (cherry picked from commit b2d5ee2e3684951b611fd2068d57cc65fd8305a3)

commit 47da6e3f47a55aeeef2c849067dd2d09fc2fe481
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Fri Jan 24 18:16:54 2014 +1000

    dix: fix button state check before changing a button mapping
    
    dev->button->down is a bitmask, not a normal array. Use the helper function to
    check, we technically allow the mapping to change after the physical button
    has been pressed (but not yet processed yet), so only check BUTTON_PROCESSED.
    
    From XSetPointerMapping(3):
    "If any of the buttons to be altered are logically in the down state,
    XSetPointerMapping returns MappingBusy, and the mapping is not changed."
    
    Reported-by: Ilja Van Sprundel <ivansprundel@ioactive.com>
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    Reviewed-by: Daniel Stone <daniel@fooishbar.org>
    (cherry picked from commit 25d10464f440b8b34594b7c988a99a830ea39a29)

commit 5e0432f797d58fe1a69ef538694f65bbba38737f
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Wed Jan 1 11:10:41 2014 -0800

    XQuartz: Avoid passing uninitialized pointers to X11ApplicationSetWindowMenu in AppleWMSetWindowMenu
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit 77df653ae3d8448be21221711851acde12c6bc1a)

commit 859ced56d9ee168796c2fcf7fa6056e0c1491f3a
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Wed Jan 1 11:04:07 2014 -0800

    XQuartz: Check for allocated memory before using it in AppleWMSetWindowMenu
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit 3bc608a361a01043b226fb9aaebf88f6fd852925)

commit 9444955d16f85926c75ee8eafb0ca796dcf16439
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Wed Jan 1 11:00:40 2014 -0800

    XQuartz: Silence a clang static analysis warning about a memory leak
    
    It seems the alanyzer can't comprehend dixSetPrivate().
    
    quartz.c:119:12: warning: Potential leak of memory pointed to by 'displayInfo'
        return quartzProcs->AddScreen(index, pScreen);
               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit 64327226ddfba8f0653615cd678d2d4336fb993d)

commit 64b0669d1c062e7e11fb0e3b8ea7fe56113fc86f
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Wed Jan 1 10:55:10 2014 -0800

    XQuartz: Silence a clang static analysis warning about a possible memory leak on exit
    
    stub.c:356:9: warning: Potential leak of memory pointed to by 'newargv'
            asl_log(aslc, NULL, ASL_LEVEL_ERR,
            ^~~~~~~
    stub.c:356:9: warning: Potential leak of memory pointed to by 'newenvp'
            asl_log(aslc, NULL, ASL_LEVEL_ERR,
            ^~~~~~~
    2 warnings generated.
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit b2f6b3497c33a4897afae80a2cf69c596b9f81e8)

commit 472e8e5d1c26573cef4bd42451230ef47791ed6f
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Wed Jan 1 10:47:52 2014 -0800

    XQuartz: Validate length in appledri before swapping
    
    Avoids potential memory corruption from bad requests
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit a03f096a85537d9e881cedaa6cb71aca43a97086)

commit 782fe5c174def75a9e4cb188c00c2fec72821472
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Wed Jan 1 10:39:56 2014 -0800

    XQuartz: Validate screen in AppleDRIQueryDirectRenderingCapable requests
    
    Return an error to the caller rather than crashing the server on
    invalid screens.
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit b3572c0d1ab7888ac26d6b2b8be6d1d19ed9af3f)

commit 045122566c0532378b50c1af3ffec3254e416fe2
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sun Dec 29 12:45:23 2013 -0800

    XQuartz: Simplify hook_run to quiet static analyzer
    
    x-hook.c:96:9: warning: Called function pointer is an uninitalized pointer value
            (*fun[i])(arg, data[i]);
            ^~~~~~~~~~~~~~~~~~~~~~~
    1 warning generated.
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit 959e8f23af7850fcaf40d6c67f5228241a36a9ab)

commit 33b2ae0f3b4a80fd962d876f7437d98fcfc27791
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sun Dec 29 12:41:18 2013 -0800

    XQuartz: Mark applicationWillTerminate: noreturn
    
    X11Controller.m:938:1: warning: method 'applicationWillTerminate:' could be declared with attribute 'noreturn'
          [-Wmissing-noreturn,Semantic Issue]
    {
    ^
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit f79af1941776fd6f1ec26c50603fcc35ca7d514b)

commit 404f26866147be1c26585e59d9795e87e0c3e5fa
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sun Dec 29 12:36:51 2013 -0800

    XQuartz: Fix get_proc_address signature
    
    indirect.c:675:28: warning: incompatible pointer types passing 'glx_gpa_proc (*)(const char *)' to parameter of type
          'glx_gpa_proc' (aka 'glx_func_ptr (*)(const char *)') [-Wincompatible-pointer-types,Semantic Issue]
        __glXsetGetProcAddress(&get_proc_address);
                               ^~~~~~~~~~~~~~~~~
    ../../../glx/glxserver.h:122:42: note: passing argument to parameter 'get_proc_address' here [Semantic Issue]
    void __glXsetGetProcAddress(glx_gpa_proc get_proc_address);
                                             ^
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit ea80279e292e59a9fe9651489f03e9f2f39810d9)

commit 7803c4075b824ece79af0425cee736025c41d901
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sun Dec 29 12:31:23 2013 -0800

    XQuartz: Fix darwinfb.h header guard
    
    ./darwinfb.h:28:9: warning: '_DARWIN_FB_H' is used as a header guard here, followed by #define of a different macro
          [-Wheader-guard,Lexical or Preprocessor Issue]
            ^~~~~~~~~~~~
    ./darwinfb.h:29:9: note: '_DARWIN_DB_H' is defined here; did you mean '_DARWIN_FB_H'? [Lexical or Preprocessor Issue]
            ^~~~~~~~~~~~
            _DARWIN_FB_H
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit 2e3ebec9520719a8e5c3c92390e83bcb5216f978)

commit 6c055f0d78349ff08a570c5dcc92c6f7b6924993
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sun Dec 29 12:22:55 2013 -0800

    XQuartz: Silence some static analyzer warnings by annotating referencing counts
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
    (cherry picked from commit 9da6c0918f40359f28fe8889d5b7cae7efcc8377)

commit 2ea973e12f5d954211e1d10085a4c74581b43aca
Author: Keith Packard <keithp@keithp.com>
Date:   Fri Dec 27 09:50:55 2013 -0800

    Bump version to 1.15.0
    
    Signed-off-by: Keith Packard <keithp@keithp.com>

commit 2eb9915eea358f941702d3dad7434197991885c5
Author: Keith Packard <keithp@keithp.com>
Date:   Thu Dec 12 15:48:08 2013 -0800

    present: Set complete notify mode to Skip as needed
    
    Skipped present pixmap calls were not setting the mode to
    PresentCompleteModeSkip for skipped operations.
    
    Signed-off-by: Keith Packard <keithp@keithp.com>

commit e487babd525ef1bd016ec7b283fa08cf9e6c6f4f
Author: Keith Packard <keithp@keithp.com>
Date:   Thu Dec 12 14:52:35 2013 -0800

    present: Don't abandon presents which are already queued for flip
    
    Presents which are not marked 'queued' and are in the window present
    list are waiting for the flip event; discarding those won't work very
    well (it'll end up trashing displayed content for the next frame), so
    skip over those when looking for duplicate frame presents
    
    Signed-off-by: Keith Packard <keithp@keithp.com>

commit ca3a5b2a8f9f627bbaa9883e16512a21c2a0b81d
Author: Keith Packard <keithp@keithp.com>
Date:   Thu Dec 12 14:17:40 2013 -0800

    present: Handle PresentOptionAsync for copy mode
    
    Check for Async flag and execute immediately if set, otherwise wait
    for the next appropriate vblank before copying.
    
    Signed-off-by: Keith Packard <keithp@keithp.com>

commit a68df147421da21528b5be2d34678383922fa352
Author: Keith Packard <keithp@keithp.com>
Date:   Thu Dec 19 14:31:07 2013 -0800

    Bump version to 1.14.99.905 (1.15 RC5)
    
    Another week, another RC. This should be the last before 1.15 final
    
    Signed-off-by: Keith Packard <keithp@keithp.com>

commit 4b1ead9d3400acc3402c2480d7cc0527750c32f0
Merge: 4d62646 929795d
Author: Keith Packard <keithp@keithp.com>
Date:   Thu Dec 19 14:14:59 2013 -0800

    Merge remote-tracking branch 'whot/for-keith'

commit 4d62646142718024b0981eb4f1fd0131e829161f
Merge: f4bfb14 81ba89d
Author: Keith Packard <keithp@keithp.com>
Date:   Mon Dec 16 09:27:57 2013 -0800

    Merge remote-tracking branch 'jeremyhu/master'

commit f4bfb14f53a939574da1f5995f0dad949898b86a
Author: Adam Jackson <ajax@redhat.com>
Date:   Thu Dec 12 10:57:40 2013 -0500

    configure: Fix a typo near dri3/shmfence detection
    
    " is not the mate of ].
    
    Reviewed-by: Jasper St. Pierre <jstpierre@mecheye.net>
    Signed-off-by: Adam Jackson <ajax@redhat.com>

commit 8248b4af31ef71ac03158871b77f20eb456dbe38
Author: Adam Jackson <ajax@redhat.com>
Date:   Fri Dec 13 15:07:48 2013 -0500

    glx: Add null pointer protection to __glGetProcAddress
    
    This can't happen when GLX is the backing window system, but can
    elsewhere.  We may as well protect against it at a high level.
    
    Reviewed-by: Eric Anholt <eric@anholt.net>
    Signed-off-by: Adam Jackson <ajax@redhat.com>

commit 128449dd6498a2f74c3770f89a9dae0f70e2b351
Author: Adam Jackson <ajax@redhat.com>
Date:   Fri Dec 13 11:39:16 2013 -0500

    present: Don't use the major/minor version from the protocol headers
    
    We want to advertise the version we implement, not the version the
    protocol headers happen to describe.
    
    Reviewed-by: Jasper St. Pierre <<jstpierre@mecheye.net>
    Signed-off-by: Adam Jackson <ajax@redhat.com>

commit ec6087bf070131bc3a26848fb9fb840f09b0e19d
Author: Adam Jackson <ajax@redhat.com>
Date:   Fri Dec 13 11:36:38 2013 -0500

    dri3: Don't use the major/minor version from the protocol headers
    
    We want to advertise the version we implement, not the version the
    protocol headers happen to describe.
    
    Reviewed-by: Jasper St. Pierre <<jstpierre@mecheye.net>
    Signed-off-by: Adam Jackson <ajax@redhat.com>

commit e6fafd3de70d315130fb6e5732cfd02a5901b788
Author: Adam Jackson <ajax@redhat.com>
Date:   Fri Dec 13 11:28:59 2013 -0500

    dri3: Guard against buggy clients
    
    There's nothing to stop a client from sending these requests to screens
    without DRI3 support, and if they do, we'll crash.  Let's not do that.
    
    Reviewed-by: Jasper St. Pierre <<jstpierre@mecheye.net>
    Signed-off-by: Adam Jackson <ajax@redhat.com>

commit 81ba89d6703a22178a153aa39478ba2d4bde262b
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Fri Dec 13 01:39:44 2013 -0800

    configure.ac: Add PRESENT_LIB to XQUARTZ_LIBS
    
    Undefined symbols for architecture x86_64:
      "_present_extension_init", referenced from:
          _staticExtensions in libXquartz.a(miinitext.o)
      "_present_register_complete_notify", referenced from:
          ___glXregisterPresentCompleteNotify in libglx.a(glxcmds.o)
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>

commit d7c9235ee261b0f780320985233e00dec5e2689c
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sat Dec 7 01:36:33 2013 -0800

    XQuartz: Use asl_log_descriptor to log stdout/stderr of child processes
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>

commit ad8111d7c971ce448905c733d65ba0cfc72bdca4
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date:   Sat Dec 7 01:14:37 2013 -0800

    darwin: Don't leave stdin/stdout closed
    
    <rdar://problem/15609419>
    
    Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>

commit 929795d50d788358d6269ce423f72c6cc40e334b
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Tue Dec 3 10:14:51 2013 +1000

    dix: fix check for grab type
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>

commit 23394c7fea0f5c33333198c87ecfecc9f6c6a791
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Tue Dec 3 08:36:45 2013 +1000

    Xi: ungrab device when releasing a passive grab without ButtonReleaseMask (#71878)
    
    If an touch triggers an async button grab and that grab does not have the
    ButtonReleaseMask set, the TouchEnd is never delivered, deliveries is 0  and
    the grab is never deactivated.
    
    If the grab is pointer async and keyboard sync, the keyboard events are stuck
    in EnqueueEvent until some other pointer event terminates the grab.
    
    Change this to check for the number of listeners. If we're about to deliver a
    TouchEnd to a passive pointer grab, the number of listeners is already 1 -
    pointer grabs always accept so other listeners were removed.
    
    X.Org Bug 71878 <http://bugs.freedesktop.org/show_bug.cgi?id=71878>
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>

commit c1d30b5bd7f90e68bc38404fd0cc32578d6d3018
Author: Ben Gamari <bgamari.foss@gmail.com>
Date:   Thu Nov 21 21:24:20 2013 -0500

    Xi: Don't ActivateEarlyAccept POINTER_REGULAR listeners
    
    Bug #71878 describes a bug resulting in the server ceasing to respond to
    keyboard input after a touch event. The problem might be the following:
    
    DeliverTouchBeginEvent tries to deliver an event to a listener of type
    LISTENER_POINTER_REGULAR, taking the following if branch,
    
        if (listener->type == LISTENER_POINTER_REGULAR ||
            listener->type == LISTENER_POINTER_GRAB) {
            rc = DeliverTouchEmulatedEvent(dev, ti, ev, listener, client, win,
                                           grab, xi2mask);
            if (rc == Success) {
                listener->state = LISTENER_IS_OWNER;
                /* async grabs cannot replay, so automatically accept this touch */
                if (dev->deviceGrab.grab &&
                    dev->deviceGrab.fromPassiveGrab &&
                    dev->deviceGrab.grab->pointerMode == GrabModeAsync)
                    ActivateEarlyAccept(dev, ti);
            }
            goto out;
        }
    
    DeliverTouchEmulatedEvent succeeds.  The deviceGrab meets all
    three of the conditions of the inner if, enters
    ActivateEarlyAccept which then fails due to,
    
        BUG_RETURN(ti->listeners[0].type != LISTENER_GRAB &&
                   ti->listeners[0].type != LISTENER_POINTER_GRAB);
    
    That is, despite listener->type == LISTENER_POINTER_REGULAR. With my
    non-existent knowledge of XINPUT, it seems like the solution here
    might be to only ActivateEarlyAccept when listener->type ==
    LISTENER_POINTER_GRAB.
    
    Signed-off-by: Ben Gamari <bgamari.foss@gmail.com>
    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>

commit fe07ec19e212a68076560d243a2a935c54589068
Author: Keith Packard <keithp@keithp.com>
Date:   Tue Dec 10 11:27:47 2013 -0800

    present: recursively set window pixmaps on flip
    
    Newly created windows inherit the pixmap of their parent, similarly,
    reparenting a tree inherits the pixmap of the destination tree.
    
    Making present preserve the invariant that unredirected windows always
    have the same pixmap as their parent ensures that the above cases work
    correctly.
    
    v2: name the recursive function to 'set_tree_pixmap' instead of 'set_window_pixmap'
    
    Signed-off-by: Keith Packard <keithp@keithp.com>
    Reviewed-by: Adam Jackson <ajax@redhat.com>

commit b3533d0b212b6747a8f9a01931253d6bdb648ee2
Author: Keith Packard <keithp@keithp.com>
Date:   Tue Dec 10 10:29:11 2013 -0800

    Bump version to 1.14.99.904 (1.15 RC4)
    
    Signed-off-by: Keith Packard <keithp@keithp.com>

commit 9a4d7572fe3be16bb5aded5f48d4217fdf725b1d
Author: Jon TURNEY <jon.turney@dronecode.org.uk>
Date:   Thu Sep 27 18:59:45 2012 +0100

    hw/xwin/glx: Rewrite WGL wrappers after Xserver conversion to direct GL dispatch
    
    v1: Rewrite by Marc Haesen of the WGL wrapper function generation script to use
    Khronos group XML.
    
    v2: Remove -dispatchheader option, since dispatch.h doesn't exist anymore, use
    the private glapi interface to construct the GL dispatch table for the native
    WGL thunks.
    
    v3:
    Rewrite to generate shims for the OpenGL 1.2.1 (GL 1.2 + GL_ARB_imaging
    +GL_ARB_multitexture + GL_ARB_texture_compression(?)) functions the server links
    directly with rather than libGL.
    
    These shims dispatch to either the mesa GL DLL, or a thunking DLL containing
    cdecl-to-stcall wrapper functions for the native GL DLL.
    
    Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
    Reviewed-by: Adam Jackson <ajax@redhat.com>

commit cb48877a3c4cfb1ae2248000fcd3443e3092bdaa
Author: Jon TURNEY <jon.turney@dronecode.org.uk>
Date:   Fri Dec 6 14:00:21 2013 +0000

    glx: Consistently use ARB-suffixed names for ARB_multitexture functions
    
    At the moment we have a mix of ARB and non-ARB suffixed forms for ARB_multitexture functions
    e.g. glMultiTexCoord1fvARB and glMultiTexCoord1dv
    
    Consistently use the ARB-suffixed form, assuming that is present in all libGL
    which provide the OpenGL 1.2.1 ABI we expect to be able to directly link with.
    
    Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
    Reviewed-by: Adam Jackson <ajax@redhat.com>

commit 1a021f57a1e75ab63e8f87704f0394162402c4d4
Author: Jon TURNEY <jon.turney@dronecode.org.uk>
Date:   Sun Dec 1 22:25:46 2013 +0000

    ephyr: Fix compilation when ./configure'd with --enable-debug
    
    /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c: In function ‘ephyrProcessMouseMotion’:
    /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c:946:188: error: ‘ephyrCurScreen’ undeclared (first use in this function)
    /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c: In function ‘ephyrProcessButtonPress’:
    /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c:980:186: error: ‘ephyrCurScreen’ undeclared (first use in this function)
    /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c: In function ‘ephyrProcessButtonRelease’:
    /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c:1007:186: error: ‘ephyrCurScreen’ undeclared (first use in this function)
    
    Fix ephyr compilation when ./configure'd with --enable-debug after commit
    46cf6bf5692ef751ec9d17ae2292565d4b13f14b, some instances of ephyrCurScreen were
    not converted to screen->pScreen->myNum.
    
    v2: Don't use a trivial local variable which will be unused when ./configure'd
    with --disable-debug
    
    Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
    Reviewed-by: Adam Jackson <ajax@redhat.com>

commit 875dbcef5bfcb6a94ef8456be6151e133408793f
Author: Jon TURNEY <jon.turney@dronecode.org.uk>
Date:   Fri Nov 29 14:29:20 2013 +0000

    configure.ac: Link XWin with present extension if we are building with it enabled
    
