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

xorg-server: Changes to 'ubuntu'



 debian/changelog                                    |    8 +++
 debian/patches/612-Fix-vcp-touches-corruption.patch |   45 ++++++++++++++++++++
 debian/patches/613-Keep-vcp-touch-class.patch       |   42 ++++++++++++++++++
 debian/patches/series                               |    2 
 4 files changed, 97 insertions(+)

New commits:
commit e088723c41bc6c451d9ce903137184143ef9211d
Author: Chase Douglas <chase.douglas@ubuntu.com>
Date:   Mon Feb 13 16:01:21 2012 -0800

    releasing version 2:1.11.4-0ubuntu3

diff --git a/debian/changelog b/debian/changelog
index b716c6a..5eb231c 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,10 +1,10 @@
-xorg-server (2:1.11.4-0ubuntu3) UNRELEASED; urgency=low
+xorg-server (2:1.11.4-0ubuntu3) precise; urgency=low
 
   * Fix touch class memory corruption
     - Add 612-Fix-vcp-touches-corruption.patch
     - Add 613-Keep-vcp-touch-class.patch
 
- -- Chase Douglas <chase.douglas@ubuntu.com>  Mon, 13 Feb 2012 15:53:23 -0800
+ -- Chase Douglas <chase.douglas@ubuntu.com>  Mon, 13 Feb 2012 15:54:04 -0800
 
 xorg-server (2:1.11.4-0ubuntu2) precise; urgency=low
 

commit 2b4c249835d9f1d60c761fec8241c4a94a88e0bb
Author: Chase Douglas <chase.douglas@ubuntu.com>
Date:   Mon Feb 13 15:53:57 2012 -0800

    Fix touch class memory corruption
    
    * Fix touch class memory corruption
      - Add 612-Fix-vcp-touches-corruption.patch
      - Add 613-Keep-vcp-touch-class.patch

diff --git a/debian/changelog b/debian/changelog
index 548eba8..b716c6a 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+xorg-server (2:1.11.4-0ubuntu3) UNRELEASED; urgency=low
+
+  * Fix touch class memory corruption
+    - Add 612-Fix-vcp-touches-corruption.patch
+    - Add 613-Keep-vcp-touch-class.patch
+
+ -- Chase Douglas <chase.douglas@ubuntu.com>  Mon, 13 Feb 2012 15:53:23 -0800
+
 xorg-server (2:1.11.4-0ubuntu2) precise; urgency=low
 
   * Fix crash when punting a touch to a non-existent owner
diff --git a/debian/patches/612-Fix-vcp-touches-corruption.patch b/debian/patches/612-Fix-vcp-touches-corruption.patch
new file mode 100644
index 0000000..53bf3e1
--- /dev/null
+++ b/debian/patches/612-Fix-vcp-touches-corruption.patch
@@ -0,0 +1,45 @@
+From 347e785fa6177b5cac29d6c361e7c54289006a7c Mon Sep 17 00:00:00 2001
+From: Chase Douglas <chase.douglas@canonical.com>
+Date: Mon, 13 Feb 2012 15:44:41 -0800
+Subject: [PATCH 1/2] Don't clobber virtual core pointer touches array length
+
+When copying the touch class, the VCP has its own touches array. The
+length of this array must be kept alongside the array itself or we get
+memory corruption.
+
+Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+---
+ Xi/exevents.c |    9 ++++++---
+ 1 files changed, 6 insertions(+), 3 deletions(-)
+
+diff --git a/Xi/exevents.c b/Xi/exevents.c
+index 671c051..51f991c 100644
+--- a/Xi/exevents.c
++++ b/Xi/exevents.c
+@@ -671,7 +671,8 @@ DeepCopyPointerClasses(DeviceIntPtr from, DeviceIntPtr to)
+ 
+     if (from->touch)
+     {
+-        TouchPointInfoPtr tmp;
++        TouchPointInfoPtr to_touches_array_tmp;
++        int to_num_touches_tmp;
+         if (!to->touch)
+         {
+             classes = to->unused_classes;
+@@ -692,9 +693,11 @@ DeepCopyPointerClasses(DeviceIntPtr from, DeviceIntPtr to)
+             } else
+                 classes->touch = NULL;
+         }
+-        tmp = to->touch->touches;
++        to_touches_array_tmp = to->touch->touches;
++        to_num_touches_tmp = to->touch->num_touches;
+         memcpy(to->touch, from->touch, sizeof(TouchClassRec));
+-        to->touch->touches = tmp;
++        to->touch->touches = to_touches_array_tmp;
++        to->touch->num_touches = to_num_touches_tmp;
+         to->touch->sourceid = from->id;
+     } else if (to->touch)
+     {
+-- 
+1.7.9
+
diff --git a/debian/patches/613-Keep-vcp-touch-class.patch b/debian/patches/613-Keep-vcp-touch-class.patch
new file mode 100644
index 0000000..03f5e5d
--- /dev/null
+++ b/debian/patches/613-Keep-vcp-touch-class.patch
@@ -0,0 +1,42 @@
+From 9c672e0fff52e99c3cc2a1cb1d50147c13663152 Mon Sep 17 00:00:00 2001
+From: Chase Douglas <chase.douglas@canonical.com>
+Date: Mon, 13 Feb 2012 15:48:18 -0800
+Subject: [PATCH 2/2] Keep virtual core pointer touch class around if new
+ slave doesn't have one
+
+The VCP may have active touch grabs. The touch records must be kept so
+these touch grabs may be accepted/rejected in the future. This means the
+touch class list will not represent the touch class of the attached
+slave device if it does not have a touch class, but we already were
+breaking that assumption by keeping a separate touches array for the
+VCP.
+
+Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
+---
+ Xi/exevents.c |    9 +++------
+ 1 files changed, 3 insertions(+), 6 deletions(-)
+
+diff --git a/Xi/exevents.c b/Xi/exevents.c
+index 51f991c..069a52c 100644
+--- a/Xi/exevents.c
++++ b/Xi/exevents.c
+@@ -699,13 +699,10 @@ DeepCopyPointerClasses(DeviceIntPtr from, DeviceIntPtr to)
+         to->touch->touches = to_touches_array_tmp;
+         to->touch->num_touches = to_num_touches_tmp;
+         to->touch->sourceid = from->id;
+-    } else if (to->touch)
+-    {
+-        ClassesPtr classes;
+-        classes = to->unused_classes;
+-        classes->touch = to->touch;
+-        to->touch      = NULL;
+     }
++    /* Don't remove touch class if from->touch is non-existent. The to device
++     * may have an active touch grab, so we need to keep the touch class record
++     * around. */
+ }
+ 
+ /**
+-- 
+1.7.9
+
diff --git a/debian/patches/series b/debian/patches/series
index 3cf4757..dbd3796 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -46,3 +46,5 @@
 609-Xi-handle-new-XIAllowEvents-request-in-inputproto-2..patch
 610-Fix-scrolling.patch
 611-Fix-touch-punt-crash.patch
+612-Fix-vcp-touches-corruption.patch
+613-Keep-vcp-touch-class.patch


Reply to: