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

libx11: Changes to 'debian-experimental'



 debian/changelog                        |    6 ++
 debian/patches/016_fedora_xim_hang.diff |   66 ++++++++++++++++++++++++++++++++
 debian/patches/series                   |    1 
 3 files changed, 72 insertions(+), 1 deletion(-)

New commits:
commit a9f7a7eab9eb2115e4676dcef32f31645664b197
Author: Julien Cristau <jcristau@debian.org>
Date:   Sun Aug 12 17:58:18 2007 +0200

    Add patch by Søren Sandman Pedersen from RedHat to fix XIM hangs

diff --git a/debian/changelog b/debian/changelog
index ade13fc..f403c47 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,7 +3,11 @@ libx11 (2:1.1.3-2) UNRELEASED; urgency=low
   * control: libx11-data Replaces old versions of libx11-6 to enable
     upgrades from Ubuntu 6.06.
 
- -- Timo Aaltonen <tjaalton@cc.hut.fi>  Thu, 29 Nov 2007 21:39:23 +0200
+  [ Julien Cristau ]
+  * Add patch by Søren Sandman Pedersen from RedHat to fix XIM hangs
+    (closes: #437437).  Thanks, Ming Hua!
+
+ -- Julien Cristau <jcristau@debian.org>  Tue, 04 Dec 2007 15:34:29 +0100
 
 libx11 (2:1.1.3-1) experimental; urgency=low
 
diff --git a/debian/patches/016_fedora_xim_hang.diff b/debian/patches/016_fedora_xim_hang.diff
new file mode 100644
index 0000000..b99008b
--- /dev/null
+++ b/debian/patches/016_fedora_xim_hang.diff
@@ -0,0 +1,66 @@
+- Fix XIM hangs when switching input context (Soren Sandmann)
+ 
+RedHat #201284, Debian #437437, fd.o #7869
+
+--- libX11-1.0.3/modules/im/ximcp/imDefLkup.c.bug-201284	2006-10-30 23:58:41.000000000 -0500
++++ libX11-1.0.3/modules/im/ximcp/imDefLkup.c	2006-10-30 23:58:41.000000000 -0500
+@@ -216,8 +216,13 @@
+     Xic		 ic,
+     BITMASK16	 mode)
+ {
+-    if (mode & XimSYNCHRONUS) /* SYNC Request */
+-	MARK_NEED_SYNC_REPLY(ic);
++    if (mode & XimSYNCHRONUS) /* SYNC Request */ {
++	if (IS_FOCUSED(ic))
++	    MARK_NEED_SYNC_REPLY(ic);
++	else
++	    _XimProcSyncReply(ic->core.im, ic);
++    }
++    
+     return True;
+ }
+ 
+--- libX11-1.0.3/modules/im/ximcp/imDefIc.c.bug-201284	2006-06-22 17:22:22.000000000 -0400
++++ libX11-1.0.3/modules/im/ximcp/imDefIc.c	2006-10-30 23:58:41.000000000 -0500
+@@ -949,6 +949,8 @@
+     (void)_XimWrite(im, len, (XPointer)buf);
+     _XimFlush(im);
+ 
++    MARK_FOCUSED(ic);
++
+     _XimRegisterFilter(ic);
+     return;
+ }
+@@ -994,6 +996,8 @@
+     (void)_XimWrite(im, len, (XPointer)buf);
+     _XimFlush(im);
+ 
++    UNMARK_FOCUSED(ic);
++    
+     _XimUnregisterFilter(ic);
+     return;
+ }
+--- libX11-1.0.3/src/xlibi18n/XimintP.h.bug-201284	2006-06-22 17:22:23.000000000 -0400
++++ libX11-1.0.3/src/xlibi18n/XimintP.h	2006-10-31 00:01:30.000000000 -0500
+@@ -244,6 +244,7 @@
+ #define IC_CONNECTED		(1L)
+ #define FABLICATED		(1L << 1)
+ #define	NEED_SYNC_REPLY		(1L << 2)
++#define FOCUSED			(1L << 3)
+ 
+ /*
+  * macro for the flag of XICPrivateRec
+@@ -269,6 +270,13 @@
+ #define	UNMARK_NEED_SYNC_REPLY(ic) \
+ 		(((Xic)ic)->private.proto.flag &= ~NEED_SYNC_REPLY)
+ 
++#define IS_FOCUSED(ic) \
++		(((Xic)ic)->private.proto.flag & FOCUSED)
++#define MARK_FOCUSED(ic) \
++		(((Xic)ic)->private.proto.flag |= FOCUSED)
++#define UNMARK_FOCUSED(ic) \
++		(((Xic)ic)->private.proto.flag &= ~FOCUSED)
++
+ /*
+  * macro for the filter_event_mask of XICPrivateRec
+  */
diff --git a/debian/patches/series b/debian/patches/series
index 7cfa97d..578104b 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -9,3 +9,4 @@
 012_ru_RU_UTF-8_XLC_LOCALE.diff
 014_add_Khmer_digraphs.diff
 015_russian_locale_alias.diff
+016_fedora_xim_hang.diff



Reply to: