xserver: Branch 'server-1.7-nominations' - 3 commits

Peter Hutterer whot at kemper.freedesktop.org
Mon Feb 15 17:36:34 PST 2010


 Xi/exevents.c      |   20 ++++++++++++++++++++
 dix/window.c       |    9 +++++++--
 randr/rrproperty.c |    5 -----
 3 files changed, 27 insertions(+), 7 deletions(-)

New commits:
commit 15e9a3fc0c4776f3ff02a59375e61d9090e35a22
Author: Julien Cristau <jcristau at debian.org>
Date:   Fri Feb 12 23:34:57 2010 +0100

    dix: restore lastDeviceEventTime update in dixSaveScreens
    
    This was removed in 6b5978dcf1f7ac3ecc2f22df06f7000f360e2066 (Do not
    reset lastDeviceEventTime when we do dixSaveScreens), but caused a
    regression for XResetScreenSaver.  Add the lastDeviceEventTime update
    back, but restrict it to that case.
    
    X.Org bug#25855 <http://bugs.freedesktop.org/25855>
    
    Reported-by: Lubos Lunak <l.lunak at suse.cz>
    Tested-by: Lubos Lunak <l.lunak at suse.cz>
    Signed-off-by: Julien Cristau <jcristau at debian.org>
    Signed-off-by: Keith Packard <keithp at keithp.com>
    (cherry picked from commit 001ce71dc11287dc94cc2fbc5d35677c046e6c04)
    
    Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>

diff --git a/dix/window.c b/dix/window.c
index caff1cb..2676a54 100644
--- a/dix/window.c
+++ b/dix/window.c
@@ -3233,8 +3233,13 @@ dixSaveScreens(ClientPtr client, int on, int mode)
 	}
     }
     screenIsSaved = what;
-    if (mode == ScreenSaverReset)
-       SetScreenSaverTimer();
+    if (mode == ScreenSaverReset) {
+	if (on == SCREEN_SAVER_FORCER) {
+	    UpdateCurrentTimeIf();
+	    lastDeviceEventTime = currentTime;
+	}
+	SetScreenSaverTimer();
+    }
     return Success;
 }
 
commit 38a83dce236da44856c075b5589d38ef0a662d4b
Author: Peter Harris <pharris at opentext.com>
Date:   Fri Feb 12 15:36:30 2010 -0500

    Don't double-swap the RandR PropertyNotify event
    
    The event is already swapped in randr.c/SRROutputPropertyNotifyEvent, so
    it should not be swapped here.
    
    X.Org Bugzilla #26511: http://bugs.freedesktop.org/show_bug.cgi?id=26511
    
    Tested-by: Leonardo Chiquitto <leonardo at ngdn.org>
    Acked-by: Adam Jackson <ajax at redhat.com>
    Reviewed-by: Julien Cristau <jcristau at debian.org>
    Signed-off-by: Peter Harris <pharris at opentext.com>
    Signed-off-by: Keith Packard <keithp at keithp.com>
    (cherry picked from commit 97b03037f4d99fcebc7603011f41c3aff9871ce2)
    
    Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>

diff --git a/randr/rrproperty.c b/randr/rrproperty.c
index 146facb..12e30e4 100644
--- a/randr/rrproperty.c
+++ b/randr/rrproperty.c
@@ -47,11 +47,6 @@ DeliverPropertyEvent(WindowPtr pWin, void *value)
 
 	event->sequenceNumber = client->sequence;
 	event->window = pRREvent->window->drawable.id;
-	if (client->swapped) {
-	    int n;
-	    swaps(&event->sequenceNumber, n);
-	    swapl(&event->window, n);
-	}
 	WriteEventsToClient(pRREvent->client, 1, (xEvent *)event);
     }
 
commit 829980a4ff36b46745cf958824338b6341302c7b
Author: Peter Hutterer <peter.hutterer at who-t.net>
Date:   Wed Jan 13 15:03:45 2010 +1000

    Xi: reset the sli pointers after copying device classes. (#25640)
    
    If the indicator flags have the XkbSLI_IsDefault bit set, the indicator map
    and names aren't their own bit of memory but rather point into the
    device->key->xkbInfo->desc structure. XkbCopySrvLedInfo knows about this and
    leaves the pointers alone.
    
    When copying the classes from the slave to the master, these pointers are
    copied and still point to the dev->key class of the slave device. If the
    slave device is removed, the memory becomes invalid and a call to modify
    this data (e.g. XkbSetIndicators) may cause a deadlock.
    
    The copying of dev->key relies on dev->kbdfeed to be already set up. Hence
    the pointers need to be reset once _both_ kbdfeed and key have been copied
    into the master device.
    
    X.Org Bug 25640 <http://bugs.freedesktop.org/show_bug.cgi?id=25640>
    Fedora Bug 540584 <https://bugzilla.redhat.com/show_bug.cgi?id=540584>
    
    Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
    Reviewed-by: Keith Packard <keithp at keithp.com>
    (cherry picked from commit 48f7298657f91843db36566b8d66d6c4c18dbd4c)
    
    Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>

diff --git a/Xi/exevents.c b/Xi/exevents.c
index cb2452b..ee32ba8 100644
--- a/Xi/exevents.c
+++ b/Xi/exevents.c
@@ -444,6 +444,26 @@ DeepCopyKeyboardClasses(DeviceIntPtr from, DeviceIntPtr to)
         to->key      = NULL;
     }
 
+    /* If a SrvLedInfoPtr's flags are XkbSLI_IsDefault, the names and maps
+     * pointer point into the xkbInfo->desc struct.  XkbCopySrvLedInfo
+     * didn't update the pointers so we need to do it manually here.
+     */
+    if (to->kbdfeed)
+    {
+        KbdFeedbackPtr k;
+
+        for (k = to->kbdfeed; k; k = k->next)
+        {
+            if (!k->xkb_sli)
+                continue;
+            if (k->xkb_sli->flags & XkbSLI_IsDefault)
+            {
+                k->xkb_sli->names = to->key->xkbInfo->desc->names->indicators;
+                k->xkb_sli->maps = to->key->xkbInfo->desc->indicators->maps;
+            }
+        }
+    }
+
     /* We can't just copy over the focus class. When an app sets the focus,
      * it'll do so on the master device. Copying the SDs focus means losing
      * the focus.


More information about the xorg-commit mailing list