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

xorg-server: Changes to 'debian-unstable'



 ChangeLog                             |  565 ++++++++++++++++++++++++++++++++++
 Xi/exevents.c                         |  174 +++++++++-
 debian/changelog                      |    9 
 dix/devices.c                         |    2 
 dix/dispatch.c                        |    5 
 dix/events.c                          |   60 ++-
 dix/getevents.c                       |    3 
 dix/touch.c                           |  122 ++++---
 glx/glapi_gentable.c                  |    2 
 hw/xfree86/modes/xf86Rotate.c         |   11 
 hw/xquartz/X11Application.m           |  154 ++++++++-
 hw/xquartz/console_redirect.c         |    2 
 hw/xquartz/darwin.c                   |   57 +--
 hw/xquartz/darwinEvents.c             |  210 +++++-------
 hw/xquartz/darwinEvents.h             |   13 
 hw/xquartz/mach-startup/bundle-main.c |    2 
 hw/xquartz/xpr/xprFrame.c             |    2 
 include/input.h                       |    6 
 os/WaitFor.c                          |   18 -
 xkb/xkbActions.c                      |   26 +
 20 files changed, 1168 insertions(+), 275 deletions(-)

New commits:
commit 8a8eba1530cbc391c43e4a285ab5976c46d83851
Author: Cyril Brulebois <kibi@debian.org>
Date:   Mon May 7 01:46:19 2012 +0200

    Upload to unstable.

diff --git a/debian/changelog b/debian/changelog
index 0315861..8c2963a 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,11 +1,11 @@
-xorg-server (2:1.12.1-2) UNRELEASED; urgency=low
+xorg-server (2:1.12.1-2) unstable; urgency=low
 
   * Merge from server-1.12-branch up to 22a1953c4a to get:
     - many XI 2.2 fixes.
     - “os: make timers signal-safe”; fixing infinite loops with the
       synaptics tap handling code.
 
- -- Cyril Brulebois <kibi@debian.org>  Mon, 07 May 2012 01:43:38 +0200
+ -- Cyril Brulebois <kibi@debian.org>  Mon, 07 May 2012 01:46:16 +0200
 
 xorg-server (2:1.12.1-1) unstable; urgency=low
 

commit 1c88bc476de6a7ffa4b9e2335976388c3adcb21d
Author: Cyril Brulebois <kibi@debian.org>
Date:   Mon May 7 01:46:13 2012 +0200

    Bump changelogs.

diff --git a/ChangeLog b/ChangeLog
index 1c66cf3..3d7e7d2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,568 @@
+commit 22a1953c4a2747d637bb926034f11134809b8d06
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date:   Thu Apr 26 21:17:54 2012 -0700
+
+    XQuartz: Make sure we tell startx the correct server binary to use in our fallback path
+    
+    With multiple servers installed, we can't be certain if X is Xorg or Xquartz
+    
+    Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+    (cherry picked from commit 93d6ba5b711cbd3f502d83e54c9739856d2e6f2a)
+
+commit 90299556db24543bb7365e8c2897deca3aa219e7
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date:   Mon Apr 30 10:01:48 2012 +1000
+
+    dix: when disabling a device, release all buttons and keys
+    
+    A suspend-induced device disable may happen before the device gets to see
+    the button release event. On resume, the server's internal state still has
+    some buttons pressed, causing inconsistent behaviour.
+    
+    Force the release and the matching events to be sent to the client.
+    
+    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+    Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
+    (cherry picked from commit f3410b97cf9b48a47bee3d15d232f8a88e75f4ef)
+    
+    Conflicts:
+    
+    	dix/devices.c
+
+commit b53cdf4c53f0787ed41281278877e0405fcb2674
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date:   Fri Apr 27 16:31:17 2012 +1000
+
+    dix: don't emulate scroll events for non-existing axes (#47281)
+    
+    Test case:
+    - create a device with REL_HWHEEL and ABS_X and ABS_Y. evdev 2.7.0 will set
+      that up as device with 1 relative axis
+    - move pointer to VGA1
+    - xrandr --output VGA1 --off
+    
+    Warps the pointer to the new spot and calls GPE with the x/y mask bits set.
+    When running through the loop to check for scroll event, this overruns the
+    axes and may try to emulate scroll events based on random garbage in the
+    memory. If that memory contained non-zero for the scroll type but near-zero
+    for the increment field, the server would hang in an infinite loop.
+    
+    This was the trigger for this suggested, never-merged, patch here:
+    http://patchwork.freedesktop.org/patch/9543/
+    
+    X.Org Bug 47281 <http://bugs.freedesktop.org/show_bug.cgi?id=47281>
+    
+    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+    Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
+    (cherry picked from commit af88b43f9e604157b74270d609c08bdfa256a792)
+
+commit 9ddf9e2388f9ac5f4c325304ab0c59c1fd5e2024
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date:   Fri Apr 27 10:52:39 2012 +1000
+
+    os: make timers signal-safe
+    
+    If TimerSet() is called from a signal handler (synaptics tap handling code)
+    may result in list corruption if we're currently inside TimerSet().
+    
+    See backtrace in
+    https://bugzilla.redhat.com/show_bug.cgi?id=814869
+    
+    Block signals for all list manipulations in the timers.
+    
+    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+    Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
+    (cherry picked from commit 08962951de969b9d8c870af8b6e47303dc0decfd)
+
+commit 345761be71b86b687f407eb8de746a33bab7ad2e
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Fri Apr 20 11:08:15 2012 -0700
+
+    TouchListenerAcceptReject: Warn and return early on bad listener index
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Bryce Harrington <bryce@canonical.com>
+    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 5c361d59c5031d9b3f7f9093a52d2b1ff4d9ae5f)
+
+commit ed33772a0d3ace5844e157ae78885ded000819ea
+Author: Michal Suchanek <hramrach@gmail.com>
+Date:   Wed Mar 28 18:12:39 2012 -0700
+
+    xfree86: workaround crash on close
+    
+    Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=41653
+    
+    Signed-off-by: Michal Suchanek <hramrach@gmail.com>
+    Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+    Tested-by: Knut Petersen <Knut_Petersen@t-online.de>
+    (cherry picked from commit fa6dddc6ce51c1b7a43fb379fb2a19550f6c8683)
+
+commit e4dbdee392c78de13fab03c3826f9453f42a8a46
+Author: Jonas Maebe <jonas.maebe@elis.ugent.be>
+Date:   Sun Apr 22 20:52:47 2012 -0700
+
+    glapi: Correct size of allocated _glapi_table struct
+    
+    The __glapi_gentable_set_remaining_noop() routine treats the _glapi_struct
+    as an array of _glapi_get_dispatch_table_size() pointers, so we have to
+    allocate _glapi_get_dispatch_table_size()*sizeof(void*) bytes rather than
+    sizeof(struct _glapi_struct) bytes.
+    
+    Signed-off-by: Jonas Maebe <jonas.maebe@elis.ugent.be>
+    Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+    (cherry picked from commit adcb48a29dcb3f32ff570551de4b014775c1e147)
+
+commit 6b45dff0240729a78a43cc74f1631b2dd5a0d6b3
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date:   Thu Apr 19 16:38:06 2012 -0700
+
+    XQuartz: darwinPointer now sends both absolute and relative motion
+    
+    This should hopefully help out wine clients that were continuing to
+    have issues after the earlier changes.
+    
+    http://xquartz.macosforge.org/trac/ticket/548
+    
+    Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+    (cherry picked from commit e34519e525559b01a63d26639f13f0487468de28)
+
+commit 0d13e62da2b3527db7b3b6de91464015eb20a514
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date:   Thu Apr 19 18:48:22 2012 -0700
+
+    XQuartz: Add a hack to better handle clicky wheel scroll mice
+    
+    We loose information from AppKit being in our way.  Before adopting
+    smooth scrolling, we always rounded-up the number of scroll button
+    clicks per NSEvent.  Now, the scroll value is accumulated in the
+    dix, and clicky scroll wheels with legacy X11 clients are seeing
+    an accumulation of error due to so many translations (button press
+    to smooth scrolling value in AppKit, passed to the dix, and then
+    synthesized into a button press).  This attempts to make the
+    situation better.
+    
+    http://xquartz.macosforge.org/trac/ticket/562
+    
+    Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+    (cherry picked from commit 662d41acdde1dcb9774fbe4054e251c708acaffe)
+
+commit 287f8271a3af18fb1a56a761fa02ec76148d9e32
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date:   Thu Apr 19 16:20:30 2012 -0700
+
+    XQuartz: Use screenInfo.{width,height} instead of grabbing it from the first screen
+    
+    Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+    (cherry picked from commit eda85290ae47d8dd497ef9335d10268bbe3e02a0)
+
+commit 67cc65ba3ca35b4eb9592e1e6f299938509cddec
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date:   Wed Apr 18 17:50:55 2012 -0700
+
+    XQuartz: Separate out tablet and mouse event delivery into separate functions
+    
+    This should have no immediate impact aside from fake mouse buttons no longer
+    working with tablets (where they aren't needed or desired anyways).  This
+    prepares us for future changes.
+    
+    Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+    (cherry picked from commit b99586c9086ac29df144ef75df92f8c0c7554651)
+
+commit 72226dc434a5d1c4ec391390fe5f2a2c34287fb3
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date:   Thu Apr 19 16:06:45 2012 -0700
+
+    XQuartz: Correct calculation of the size of our file descriptor array in console_redirect
+    
+    Reported-by: Joe Rohde <joer@valvesoftware.com>
+    Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+    (cherry picked from commit 30623d6ff7bca223f9e1a825e86bd317eef8bf16)
+
+commit 8a48d44574375ba4fa85c5a59678998811ea4e80
+Author: Jeremy Huddleston <jeremyhu@apple.com>
+Date:   Wed Apr 18 01:01:44 2012 -0700
+
+    XQuartz: Fix a deadlock in pre-dispatch code
+    
+    The fact that this has been in place so long makes me really wonder if
+    anybody cares about this running in Tiger or Leopard.
+    
+    Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+    (cherry picked from commit b4c4c65a35640e7274ccd4228f62110147878b72)
+
+commit 9ef48c9ffff6704dbe7c976d86527f22b0e1d114
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Wed Apr 18 18:21:54 2012 -0700
+
+    Replay original touch begin event instead of generated begin event
+    
+    The generated event does not have axes other than X and Y and has a
+    newer timestamp. In particular, the newer timestamp may be newer than
+    the real touch end event, which may be stuck in the syncEvents queue. If
+    a client uses the timestamps for grabbing bad things may happen.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 00cf1c40b28417d7035c2917d048553eb720023c)
+
+commit 73cd880fe05c941391a8604406e9ecf657a77f02
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Wed Apr 18 11:15:40 2012 -0700
+
+    Update currentTime in dispatch loop
+    
+    A request, like input device grabs, may check a request timestamp
+    against currentTime. It is possible for currentTime to lag a previously
+    sent event timestamp. If the client makes a request based on such an
+    event timestamp, the request may fail the validity check against
+    currentTime unless we always update the time before processing the
+    request.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 312910b4e34215aaa50fc0c6092684d5878dc32f)
+
+commit 96d8df5bc9d400d55830b23afe5525b222f8dfc7
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Tue Apr 17 11:40:15 2012 -0700
+
+    Update device state including when touch record does not exist
+    
+    If a touch is physically active, the pointer core state should reflect
+    that the first button is pressed. Currently, this only occurs when there
+    are active listeners of the touch sequence. By moving the device state
+    updating to the beginning of touch processing we ensure it is updated
+    according to the processed physical state no matter what.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit a986f2f30cbe2a00e72ded7315c4951d7703e549)
+
+commit a9dbdb49698a15ba9bdf4172a6e2fef6133244f3
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Wed Apr 18 12:04:58 2012 -0700
+
+    Check other clients' core masks properly when adding touch listener
+    
+    The current code checks the core event mask as though it were an XI
+    mask. This change fixes the checks so the proper client and event masks
+    are used.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit ec9c4295830c3de610e65aca17f4da4a7af3c4c5)
+
+commit 04431dd5e60dc91b61767157914b874515a18feb
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Tue Apr 17 11:39:10 2012 -0700
+
+    Ensure touch is ended when last listener is rejected
+    
+    Currently, the touch is only logically ended if the touch has physically
+    ended. If the touch hasn't physically ended, the touch record is never
+    ended. If there aren't any more listeners, we don't need to keep the dix
+    touch record around any more.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit e175971a6f44d94aa8306dc6b9228ccb2c8a0b4d)
+
+commit 8ce9616a2ccd3f80bf56d69cb9e3fad89996fffb
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Tue Apr 17 10:49:14 2012 -0700
+
+    Create a new dix touch record for an emulated touch with no listeners
+    
+    As a special case, if a still physically active pointer emulated touch
+    has no listeners and the device is explicitly grabbed for pointer
+    events, create a new dix touch record for the grab only.
+    
+    This allows for clients to "hand off" grabs. For example, when dragging
+    a window under compiz the window decorator sees the button press and
+    then ungrabs the implicit grab. It then tells compiz to grab the device,
+    and compiz then moves the window with the pointer motion. This is racy,
+    but is allowed by the input protocol for pointer events when there are
+    no other clients with a grab on the device.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit d0449851d1233543c3133d77e0ab7233319cdf5f)
+
+commit da9cedb1e5e50acc7d3dc40398e1a460b7e3cfdc
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Tue Apr 17 13:56:08 2012 -0700
+
+    Rename TouchEnsureSprite to TouchBuildSprite and event type checks
+    
+    The function will be used for building a sprite for pointer emulation
+    after an explicit device grab. This commit refactors the code so that
+    TouchBuildSprite will function with any event type and moves the checks
+    to the caller.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 3d06bfe93d33cfe6150d8fb0058ee7bc8d80622b)
+
+commit 7be71cb0894052943f94638ffa405cf8dd61bc4a
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Tue Apr 17 08:39:38 2012 -0700
+
+    When activating an explicit grab, update owning listener
+    
+    Pointer passive grabs may be changed by the grabbing client. This allows
+    for a selecting client to change an implicit grab to an active grab,
+    which is the mechanism used for pop-up windows like application menus.
+    
+    We need to do the same thing with touches. If the grabbing client is the
+    owner of a touch sequence, change the listener record to reflect the new
+    grab. If the grabbing client is not the owner, nothing changes for the
+    touch.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 2efbed23c29020f9994ab7c3155ce7386950dc7a)
+
+commit 8ccc6ad63733c7de6bd64b1b11169836d941455b
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Mon Apr 16 15:53:51 2012 -0700
+
+    Don't deactivate implicit pointer grab on fake touch end event
+    
+    Fake touch end events are generated by touch acceptance and rejection.
+    These should not cause implicit pointer grabs to be deactivated.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit ef64b5ee97099618cf2e2cbbd3e471095695ae24)
+
+commit ea3afab228f44d9a41905daeda4c0f9236dbf8e6
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Mon Apr 16 15:31:47 2012 -0700
+
+    End a pointer emulated touch event only on a "real" end event
+    
+    Fake end events are generated by touch acceptance or rejection. These
+    should not end the touch point.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit fc518cd9f59060cc19bb90361767c0f47f0e25eb)
+
+commit fac2c4a5dc1d19bb347729eee8b1bbfc981b853a
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Mon Apr 16 14:19:59 2012 -0700
+
+    On touch accept, only process end event for owner if it has seen the end
+    
+    We still need to generate the touch ownership event to process the
+    ending of the touch event in the case where the owner has the end
+    already.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 80d7d1ec6a9d61aa96e7d019dc1bee29d90cea34)
+
+commit aaf0063bde791659009eb9001485ac8c15745ae8
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Wed Apr 11 11:14:51 2012 -0700
+
+    Fix copy/paste error from before git history in UpdateCurrentTimeIf()
+    
+    See UpdateCurrentTime() for reference. I don't know what bug this might
+    trigger, but it wouldn't hurt to fix this.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 8dfd98245d2c44a1eb4c8b7c275e6cfc10fe40f1)
+
+commit acb74b9b36b55d4f80d85fd6a2790b7c72e197a5
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Wed Apr 11 08:17:25 2012 -0700
+
+    When deactivating an explicit pointer grab, reject all grabs on touches
+    
+    Explicit pointer grabs are placed at the head of the touch listener
+    array for pointer emulated touches. If the grab is deactivated, we must
+    remove it from all touches for the device.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 6ca30cb33e829b4edd01822367e44ffe6f0951b0)
+
+commit 0dea2b1c935ed4c80621e7f5d6fa5193ae09187a
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Wed Apr 11 08:13:17 2012 -0700
+
+    Accept touch sequence for pointer listener after second event delivery
+    
+    This is a bit of unimplemented code for touchscreen pointer emulation. A
+    pointer grabbing client currently never accepts the touch sequence. The
+    sequence must be accepted once any touch-derived event is irrevocably
+    delivered to a client.
+    
+    The first pointer event, derived from a touch begin event, may be caught
+    in a sync grab and then replayed. This is essentially a revocable
+    delivery of an event. Thus, we must wait till a non-begin event is
+    delivered.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit cacdb9a74065ccba7d50a82e14abdf04b36c5309)
+
+commit 2bb2eeb05c973ba410773e380e49c2503a2fe9e6
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Wed Apr 11 08:12:08 2012 -0700
+
+    Split out helper function TouchListenerAcceptReject()
+    
+    This will be used for accepting and rejecting touches in the future.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 447fe7a1a72513aa68145962c47894242c589cc9)
+
+commit a37539e794e2bff87ea68e0023cd0cce2bb8de60
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Wed Apr 4 12:59:55 2012 -0700
+
+    Only set XI2 mask if pointer emulation is for XI2 client
+    
+    The current code returns a reference to memory that may not actually be
+    an XI2 mask. Instead, only return a value when an XI2 client has
+    selected for events.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+    Acked-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 93c33403642a3de3c9d141ad7940a7b880846aad)
+
+commit d21d69c2d6b1eb292e9d3f6682339e93603913c9
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Wed Apr 4 12:57:40 2012 -0700
+
+    Check core event mask properly for pointer emulated touch events
+    
+    The current code checks the core event mask as though it were an XI2
+    mask. This change fixes the checks so the proper client and event masks
+    are used.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+    Acked-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 4c1dfd21937efc6a85fb204a73dd7d7151d54daa)
+
+commit 3d3ed6023077c0324fcbf446f387edb1db677b84
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Tue Apr 3 17:31:01 2012 -0700
+
+    Use touch state when querying pointer through core protocol
+    
+    QueryPointer is part of the core protocol. As such, it knows nothing
+    about touch devices. Touches are converted to button 1 press, pointer
+    motion, and button 1 release for core clients, so we should ensure the
+    pointer state mask has button 1 set when XQueryPointer is used.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 12188c8a8a537b38b1ca4cf8c0de5447e19c886a)
+
+commit 50b71dcfb8b2ec14a55a119f042509d69847d776
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Tue Apr 10 17:12:42 2012 -0700
+
+    Ensure sequential touches are pointer emulated sequentially
+    
+    Issue:
+    * Two sequential touches (i.e. down, up, down, up)
+    * Both are grabbed by a touch grab
+    * Both have a second listener in the form of a pointer grab or selection
+    * The second and first touches are rejected in that order
+    
+    The first touch must be pointer emulated before the second touch, so the
+    second touch must be paused until the first touch is rejected or
+    accepted and all events are delivered to pointer clients.
+    
+    This change ensures all pointer emulated events are emitted
+    sequentially. It necessarily imposes a delay on further touch events
+    when pointer grabs and selections are used, but there is no way around
+    it.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 32ece7c09bf0ebc3d99b4078aacebbd44314776a)
+
+commit fb01dfb55a6a718affa9354c384823e462ee784a
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Tue Apr 10 17:12:41 2012 -0700
+
+    Update event type when delivering end event to a pointer listener
+    
+    Just like when we deliver to a touch listener, we must convert a touch
+    end event to an update event for further clients. This also ensures that
+    the touch record is not deleted at the end of ProcessTouchEvent().
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 163b0f375d73c05873fb341652de3ed347337828)
+
+commit b56c1f95bb2d22996651e0a5ca6b6b0e71710a7b
+Author: Chase Douglas <chase.douglas@canonical.com>
+Date:   Tue Apr 10 17:12:40 2012 -0700
+
+    Don't update listener after deactivating implicit pointer grab
+    
+    After the pointer grab is deactivated, the touch listener record is
+    updated at the end of DeliverTouchEmulatedEvent. However, the touch
+    record is ended when the grab is deactivated, so the update to the
+    listener record is in an array of memory that has been freed.
+    
+    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 210cd12c47d063f97915ff23292b61d09abfd73a)
+
+commit 8ca5a94f454d04ed5f1d0b18272a838b8e7f1e7a
+Author: Andreas Wettstein <wettstein509@solnet.ch>
+Date:   Sat Feb 25 20:48:17 2012 +0100
+
+    XKB: Redirect actions defunct with Gtk3 (XInput?)
+    
+    When redirect actions are used with Gtk3, Gtk3 complained about
+    events not holding a GdkDevice.  This was caused by device IDs
+    not being set for redirect actions.
+    
+    More seriously, Gtk3 did not receive state changes redirect
+    actions might specify.  This was because event_set_state in
+    dix/inpututils.c accesses the prev_state field, but the changes
+    for the redirect action were only put into the state field.
+    
+    Signed-off-by: Andreas Wettstein <wettstein509@solnet.ch>
+    Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+    (cherry picked from commit 9e017cf0cf1f0c9d0d9c2cfeb82ea5dc0eb5905e)
+
+commit d75da4eccbabc3f83937cbd4eb2d6be2fd27a4b9
+Author: Peter Hutterer <peter.hutterer@who-t.net>
+Date:   Mon Feb 20 12:09:33 2012 +1000
+
+    dix: IsFloating() on master devices is always false
+    
+    There are a few subtle bugs during startup where IsFloating() returns true
+    if the device is a master device that is not yet paired with its keyboard
+    device.
+    
+    Force IsFloating() to always return FALSE for master devices, that was the
+    intent after all and any code that relies on the other behaviour should be
+    fixed instead.
+    
+    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+    Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+    Tested-by: Jon TURNEY <jon.turney@dronecode.org.uk>
+    (cherry picked from commit 5497ce3da442d27c2dc7796bfef6ccd670bbadc4)
+
 commit 38e73f7fc29fe8e9defa8a0516a50ac3a84e10c2
 Author: Jeremy Huddleston <jeremyhu@apple.com>
 Date:   Fri Apr 13 15:44:08 2012 -0700
diff --git a/debian/changelog b/debian/changelog
index e655d89..0315861 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,12 @@
+xorg-server (2:1.12.1-2) UNRELEASED; urgency=low
+
+  * Merge from server-1.12-branch up to 22a1953c4a to get:
+    - many XI 2.2 fixes.
+    - “os: make timers signal-safe”; fixing infinite loops with the
+      synaptics tap handling code.
+
+ -- Cyril Brulebois <kibi@debian.org>  Mon, 07 May 2012 01:43:38 +0200
+
 xorg-server (2:1.12.1-1) unstable; urgency=low
 
   * New upstream release.

commit 22a1953c4a2747d637bb926034f11134809b8d06
Author: Jeremy Huddleston <jeremyhu@apple.com>
Date:   Thu Apr 26 21:17:54 2012 -0700

    XQuartz: Make sure we tell startx the correct server binary to use in our fallback path
    
    With multiple servers installed, we can't be certain if X is Xorg or Xquartz
    
    Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
    (cherry picked from commit 93d6ba5b711cbd3f502d83e54c9739856d2e6f2a)

diff --git a/hw/xquartz/mach-startup/bundle-main.c b/hw/xquartz/mach-startup/bundle-main.c
index d1ad6f7..cabdf1e 100644
--- a/hw/xquartz/mach-startup/bundle-main.c
+++ b/hw/xquartz/mach-startup/bundle-main.c
@@ -78,7 +78,7 @@ FatalError(const char *f, ...) _X_ATTRIBUTE_PRINTF(1, 2) _X_NORETURN;
 extern int noPanoramiXExtension;
 
 #define DEFAULT_CLIENT X11BINDIR "/xterm"
-#define DEFAULT_STARTX X11BINDIR "/startx"
+#define DEFAULT_STARTX X11BINDIR "/startx -- " X11BINDIR "/Xquartz"
 #define DEFAULT_SHELL  "/bin/sh"
 
 #ifndef BUILD_DATE

commit 90299556db24543bb7365e8c2897deca3aa219e7
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Mon Apr 30 10:01:48 2012 +1000

    dix: when disabling a device, release all buttons and keys
    
    A suspend-induced device disable may happen before the device gets to see
    the button release event. On resume, the server's internal state still has
    some buttons pressed, causing inconsistent behaviour.
    
    Force the release and the matching events to be sent to the client.
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
    (cherry picked from commit f3410b97cf9b48a47bee3d15d232f8a88e75f4ef)
    
    Conflicts:
    
    	dix/devices.c

diff --git a/dix/devices.c b/dix/devices.c
index 0125504..d0e99bd 100644
--- a/dix/devices.c
+++ b/dix/devices.c
@@ -432,6 +432,8 @@ DisableDevice(DeviceIntPtr dev, BOOL sendevent)
     if (*prev != dev)
         return FALSE;
 
+    ReleaseButtonsAndKeys(dev);
+
     /* float attached devices */
     if (IsMaster(dev)) {
         for (other = inputInfo.devices; other; other = other->next) {

commit b53cdf4c53f0787ed41281278877e0405fcb2674
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Fri Apr 27 16:31:17 2012 +1000

    dix: don't emulate scroll events for non-existing axes (#47281)
    
    Test case:
    - create a device with REL_HWHEEL and ABS_X and ABS_Y. evdev 2.7.0 will set
      that up as device with 1 relative axis
    - move pointer to VGA1
    - xrandr --output VGA1 --off
    
    Warps the pointer to the new spot and calls GPE with the x/y mask bits set.
    When running through the loop to check for scroll event, this overruns the
    axes and may try to emulate scroll events based on random garbage in the
    memory. If that memory contained non-zero for the scroll type but near-zero
    for the increment field, the server would hang in an infinite loop.
    
    This was the trigger for this suggested, never-merged, patch here:
    http://patchwork.freedesktop.org/patch/9543/
    
    X.Org Bug 47281 <http://bugs.freedesktop.org/show_bug.cgi?id=47281>
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
    (cherry picked from commit af88b43f9e604157b74270d609c08bdfa256a792)

diff --git a/dix/getevents.c b/dix/getevents.c
index fa85fe7..4e0af45 100644
--- a/dix/getevents.c
+++ b/dix/getevents.c
@@ -1574,6 +1574,9 @@ GetPointerEvents(InternalEvent *events, DeviceIntPtr pDev, int type,
     /* Now turn the smooth-scrolling axes back into emulated button presses
      * for legacy clients, based on the integer delta between before and now */
     for (i = 0; i < valuator_mask_size(&mask); i++) {
+        if (i >= pDev->valuator->numAxes)
+            break;
+
         if (!valuator_mask_isset(&mask, i))
             continue;
 

commit 9ddf9e2388f9ac5f4c325304ab0c59c1fd5e2024
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Fri Apr 27 10:52:39 2012 +1000

    os: make timers signal-safe
    
    If TimerSet() is called from a signal handler (synaptics tap handling code)
    may result in list corruption if we're currently inside TimerSet().
    
    See backtrace in
    https://bugzilla.redhat.com/show_bug.cgi?id=814869
    
    Block signals for all list manipulations in the timers.
    
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
    (cherry picked from commit 08962951de969b9d8c870af8b6e47303dc0decfd)

diff --git a/os/WaitFor.c b/os/WaitFor.c
index 4c3be34..59f3af6 100644
--- a/os/WaitFor.c
+++ b/os/WaitFor.c
@@ -382,6 +382,7 @@ CheckAllTimers(void)
     OsTimerPtr timer;
     CARD32 now;
 
+    OsBlockSignals();
  start:
     now = GetTimeInMillis();
 
@@ -391,6 +392,7 @@ CheckAllTimers(void)
             goto start;
         }
     }
+    OsReleaseSignals();
 }
 
 static void
@@ -398,11 +400,13 @@ DoTimer(OsTimerPtr timer, CARD32 now, OsTimerPtr *prev)
 {
     CARD32 newTime;
 
+    OsBlockSignals();
     *prev = timer->next;
     timer->next = NULL;
     newTime = (*timer->callback) (timer, now, timer->arg);
     if (newTime)
         TimerSet(timer, 0, newTime, timer->callback, timer->arg);
+    OsReleaseSignals();
 }
 
 OsTimerPtr
@@ -418,6 +422,7 @@ TimerSet(OsTimerPtr timer, int flags, CARD32 millis,
             return NULL;
     }
     else {
+        OsBlockSignals();
         for (prev = &timers; *prev; prev = &(*prev)->next) {
             if (*prev == timer) {
                 *prev = timer->next;
@@ -426,6 +431,7 @@ TimerSet(OsTimerPtr timer, int flags, CARD32 millis,
                 break;
             }
         }
+        OsReleaseSignals();
     }
     if (!millis)
         return timer;
@@ -445,26 +451,32 @@ TimerSet(OsTimerPtr timer, int flags, CARD32 millis,
         if (!millis)
             return timer;
     }
+    OsBlockSignals();
     for (prev = &timers;
          *prev && (int) ((*prev)->expires - millis) <= 0;
          prev = &(*prev)->next);
     timer->next = *prev;
     *prev = timer;
+    OsReleaseSignals();
     return timer;
 }
 
 Bool
 TimerForce(OsTimerPtr timer)
 {
+    int rc = FALSE;
     OsTimerPtr *prev;
 
+    OsBlockSignals();
     for (prev = &timers; *prev; prev = &(*prev)->next) {
         if (*prev == timer) {
             DoTimer(timer, GetTimeInMillis(), prev);
-            return TRUE;
+            rc = TRUE;
+            break;
         }
     }
-    return FALSE;
+    OsReleaseSignals();
+    return rc;
 }
 
 void
@@ -474,12 +486,14 @@ TimerCancel(OsTimerPtr timer)
 
     if (!timer)
         return;
+    OsBlockSignals();
     for (prev = &timers; *prev; prev = &(*prev)->next) {
         if (*prev == timer) {
             *prev = timer->next;
             break;
         }
     }
+    OsReleaseSignals();
 }
 
 void

commit 345761be71b86b687f407eb8de746a33bab7ad2e
Author: Chase Douglas <chase.douglas@canonical.com>
Date:   Fri Apr 20 11:08:15 2012 -0700

    TouchListenerAcceptReject: Warn and return early on bad listener index
    
    Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
    Reviewed-by: Bryce Harrington <bryce@canonical.com>
    Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
    (cherry picked from commit 5c361d59c5031d9b3f7f9093a52d2b1ff4d9ae5f)

diff --git a/dix/touch.c b/dix/touch.c
index dd16367..401cb98 100644
--- a/dix/touch.c
+++ b/dix/touch.c
@@ -966,6 +966,11 @@ TouchListenerAcceptReject(DeviceIntPtr dev, TouchPointInfoPtr ti, int listener,
     int nev;
     int i;
 
+    BUG_WARN(listener < 0);
+    BUG_WARN(listener >= ti->num_listeners);
+    if (listener < 0 || listener >= ti->num_listeners)
+        return BadMatch;
+
     if (listener > 0) {
         if (mode == XIRejectTouch)
             TouchRejected(dev, ti, ti->listeners[listener].listener, NULL);

commit ed33772a0d3ace5844e157ae78885ded000819ea
Author: Michal Suchanek <hramrach@gmail.com>
Date:   Wed Mar 28 18:12:39 2012 -0700

    xfree86: workaround crash on close
    
    Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=41653
    
    Signed-off-by: Michal Suchanek <hramrach@gmail.com>
    Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
    Tested-by: Knut Petersen <Knut_Petersen@t-online.de>
    (cherry picked from commit fa6dddc6ce51c1b7a43fb379fb2a19550f6c8683)

diff --git a/hw/xfree86/modes/xf86Rotate.c b/hw/xfree86/modes/xf86Rotate.c
index 85d7557..cbc8687 100644
--- a/hw/xfree86/modes/xf86Rotate.c
+++ b/hw/xfree86/modes/xf86Rotate.c
@@ -290,14 +290,19 @@ xf86RotateDestroy(xf86CrtcPtr crtc)
      * Clean up damage structures when no crtcs are rotated
      */
     if (xf86_config->rotation_damage) {
+        DrawablePtr screenDrawable = NULL;
+        if (pScreen && pScreen->root)
+            screenDrawable = &pScreen->root->drawable;
         /* Free damage structure */
         if (xf86_config->rotation_damage_registered) {
-            DamageUnregister(&pScreen->root->drawable,
-                             xf86_config->rotation_damage);
+            if (screenDrawable)
+                DamageUnregister(screenDrawable,
+                        xf86_config->rotation_damage);
             xf86_config->rotation_damage_registered = FALSE;
             DisableLimitedSchedulingLatency();
         }
-        DamageDestroy(xf86_config->rotation_damage);
+        if (screenDrawable)
+            DamageDestroy(xf86_config->rotation_damage);
         xf86_config->rotation_damage = NULL;
     }
 }

commit e4dbdee392c78de13fab03c3826f9453f42a8a46
Author: Jonas Maebe <jonas.maebe@elis.ugent.be>
Date:   Sun Apr 22 20:52:47 2012 -0700

    glapi: Correct size of allocated _glapi_table struct
    
    The __glapi_gentable_set_remaining_noop() routine treats the _glapi_struct
    as an array of _glapi_get_dispatch_table_size() pointers, so we have to
    allocate _glapi_get_dispatch_table_size()*sizeof(void*) bytes rather than
    sizeof(struct _glapi_struct) bytes.
    
    Signed-off-by: Jonas Maebe <jonas.maebe@elis.ugent.be>
    Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
    (cherry picked from commit adcb48a29dcb3f32ff570551de4b014775c1e147)

diff --git a/glx/glapi_gentable.c b/glx/glapi_gentable.c
index 1fb1431..4b28015 100644
--- a/glx/glapi_gentable.c
+++ b/glx/glapi_gentable.c
@@ -113,7 +113,7 @@ __glapi_gentable_set_remaining_noop(struct _glapi_table *disp)
 struct _glapi_table *
 _glapi_create_table_from_handle(void *handle, const char *symbol_prefix)
 {
-    struct _glapi_table *disp = calloc(1, sizeof(struct _glapi_table));
+    struct _glapi_table *disp = calloc(_glapi_get_dispatch_table_size(), sizeof(void*));
     char symboln[512];
 
     if (!disp)

commit 6b45dff0240729a78a43cc74f1631b2dd5a0d6b3
Author: Jeremy Huddleston <jeremyhu@apple.com>
Date:   Thu Apr 19 16:38:06 2012 -0700

    XQuartz: darwinPointer now sends both absolute and relative motion
    
    This should hopefully help out wine clients that were continuing to
    have issues after the earlier changes.
    
    http://xquartz.macosforge.org/trac/ticket/548
    
    Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
    (cherry picked from commit e34519e525559b01a63d26639f13f0487468de28)

diff --git a/hw/xquartz/X11Application.m b/hw/xquartz/X11Application.m
index 3517c49..b686b00 100644
--- a/hw/xquartz/X11Application.m
+++ b/hw/xquartz/X11Application.m
@@ -214,7 +214,8 @@ message_kit_thread(SEL selector, NSObject *arg)
     if (state) {
         if (bgMouseLocationUpdated) {
             DarwinSendPointerEvents(darwinPointer, MotionNotify, 0,
-                                    bgMouseLocation.x, bgMouseLocation.y);
+                                    bgMouseLocation.x, bgMouseLocation.y,
+                                    0.0, 0.0);
             bgMouseLocationUpdated = FALSE;
         }
         DarwinSendDDXEvent(kXquartzActivate, 0);
@@ -1547,14 +1548,16 @@ handle_mouse:
         if (bgMouseLocationUpdated) {
             if (!(ev_type == MotionNotify && ev_button == 0)) {
                 DarwinSendPointerEvents(darwinPointer, MotionNotify, 0,
-                                        location.x, location.y);
+                                        location.x, location.y,
+                                        0.0, 0.0);
             }
             bgMouseLocationUpdated = FALSE;


Reply to: