X Strike Force SVN commit: rev 504 - in trunk/debian: . patches
Author: branden
Date: 2003-09-10 15:48:13 -0500 (Wed, 10 Sep 2003)
New Revision: 504
Removed:
trunk/debian/patches/095_fix_Xinput_deadlock.diff
Modified:
trunk/debian/changelog
trunk/debian/patches/000_stolen_from_HEAD.diff
Log:
Improve fix for #191463 (fix hangs when threaded apps use XInput library),
using the fix committed to upstream CVS HEAD after analysis by Bastien
Nocera, Owen Taylor, and Egbert Eich.
- debian/patches/095_fix_Xinput_deadlock.diff: out with the old
- debian/patches/000_stolen_from_HEAD.diff: in with the new
Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog 2003-09-10 20:27:31 UTC (rev 503)
+++ trunk/debian/changelog 2003-09-10 20:48:13 UTC (rev 504)
@@ -98,8 +98,14 @@
+ Fix an XAA pixmap cache server crash that can happen in some cases
when the off-screen memory is heavily fragmented. (Closes: #208804)
- -- Branden Robinson <branden@debian.org> Wed, 10 Sep 2003 15:20:48 -0500
+ * Improve fix for #191463 (fix hangs when threaded apps use XInput library),
+ using the fix committed to upstream CVS HEAD after analysis by Bastien
+ Nocera, Owen Taylor, and Egbert Eich.
+ + patch #000_stolen_from_HEAD: in with the new
+ + patch #095: out with the old (deleted)
+ -- Branden Robinson <branden@debian.org> Wed, 10 Sep 2003 15:45:09 -0500
+
xfree86 (4.2.1-11) unstable; urgency=medium
* urgency set to medium because bug #206790 bites a lot of people (but,
Modified: trunk/debian/patches/000_stolen_from_HEAD.diff
===================================================================
--- trunk/debian/patches/000_stolen_from_HEAD.diff 2003-09-10 20:27:31 UTC (rev 503)
+++ trunk/debian/patches/000_stolen_from_HEAD.diff 2003-09-10 20:48:13 UTC (rev 504)
@@ -279,6 +279,13 @@
when the off-screen memory is heavily fragmented (David Dawes, based on
#5752, Koike Kazuhiko, Chisato Yamauchi).
+(xc/lib/Xi/XExtInt.c,
+ xc/lib/Xi/XGetVers.c,
+ xc/lib/Xi/XIint.h):
+ 282. Fixing deadlock in libXi - when is called _XLockDisplay() twice -
+ when calling a Xi function that calls XGetExtensionVersion() (Bugzilla
+ #260, Bastien Nocera, Owen Taylor).
+
Index: xc/nls/XI18N_OBJS/Imakefile
===================================================================
RCS file: /cvs/xc/nls/XI18N_OBJS/Imakefile,v
@@ -5570,3 +5577,83 @@
if(!Num512) { /* no room */
} else if((Num512 < 4) || (!Target512)) {
while(Num512) {
+--- xc/lib/Xi/XGetVers.c 2002-10-16 02:37:29.000000000 +0200
++++ xc/lib/Xi/XGetVers.c 2003-07-08 13:58:15.000000000 +0200
+@@ -71,12 +71,33 @@
+ char *name;
+ #endif
+ {
++ XExtensionVersion *ext;
++
++ LockDisplay (dpy);
++ ext = _XiGetExtensionVersion (dpy, name);
++ if (ext != NoSuchExtension) { /* This is unlocked in _XiCheckExtInit() */
++ UnlockDisplay (dpy);
++ SyncHandle();
++ }
++ return (ext);
++ }
++
++XExtensionVersion
++#if NeedFunctionPrototypes
++*_XiGetExtensionVersion (
++ register Display *dpy,
++ _Xconst char *name)
++#else
++*_XiGetExtensionVersion (dpy, name)
++ register Display *dpy;
++ char *name;
++#endif
++ {
+ xGetExtensionVersionReq *req;
+ xGetExtensionVersionReply rep;
+ XExtensionVersion *ext;
+ XExtDisplayInfo *info = XInput_find_display (dpy);
+
+- LockDisplay (dpy);
+ if (_XiCheckExtInit(dpy, Dont_Check) == -1)
+ return ((XExtensionVersion *) NoSuchExtension);
+
+@@ -89,8 +110,6 @@
+
+ if (! _XReply (dpy, (xReply *) &rep, 0, xTrue))
+ {
+- UnlockDisplay(dpy);
+- SyncHandle();
+ return (XExtensionVersion *) NULL;
+ }
+ ext = (XExtensionVersion *) Xmalloc (sizeof (XExtensionVersion));
+@@ -103,8 +122,6 @@
+ ext->minor_version = rep.minor_version;
+ }
+ }
+- UnlockDisplay(dpy);
+- SyncHandle();
+ return (ext);
+ }
+
+--- xc/lib/Xi/XIint.h 2001-08-01 02:44:39.000000000 +0200
++++ xc/lib/Xi/XIint.h 2003-07-08 13:58:15.000000000 +0200
+@@ -21,4 +21,11 @@
+ #endif
+ );
+
++extern XExtensionVersion * _XiGetExtensionVersion(
++#if NeedFunctionPrototypes
++ Display*,
++ _Xconst char*
++#endif
++);
++
+ #endif
+--- xc/lib/Xi/XExtInt.c 2002-10-16 02:37:28.000000000 +0200
++++ xc/lib/Xi/XExtInt.c 2003-07-08 13:58:15.000000000 +0200
+@@ -196,7 +196,7 @@
+ return (-1);
+ }
+ ((XInputData *) info->data)->vers =
+- XGetExtensionVersion (dpy, "XInputExtension");
++ _XiGetExtensionVersion (dpy, "XInputExtension");
+ }
+
+ if (versions[version_index].major_version > Dont_Check)
Deleted: trunk/debian/patches/095_fix_Xinput_deadlock.diff
===================================================================
--- trunk/debian/patches/095_fix_Xinput_deadlock.diff 2003-09-10 20:27:31 UTC (rev 503)
+++ trunk/debian/patches/095_fix_Xinput_deadlock.diff 2003-09-10 20:48:13 UTC (rev 504)
@@ -1,89 +0,0 @@
-$Id$
-
-This patch by Bastien Nocera, reviewed by Owen Taylor.
-
-See <http://bugs.xfree86.org/cgi-bin/bugzilla/show_bug.cgi?id=260>.
-
-Hasn't appeared in XFree86 CVS as of 2003-06-26.
-
-diff -urN xc/lib/Xi/XExtInt.c xc/lib/Xi/XExtInt.c
---- xc/lib/Xi/XExtInt.c 2002-10-16 01:37:28.000000000 +0100
-+++ xc/lib/Xi/XExtInt.c 2003-06-24 00:09:49.000000000 +0100
-@@ -196,7 +196,7 @@
- return (-1);
- }
- ((XInputData *) info->data)->vers =
-- XGetExtensionVersion (dpy, "XInputExtension");
-+ _XiGetExtensionVersion (dpy, "XInputExtension");
- }
-
- if (versions[version_index].major_version > Dont_Check)
-diff -urN xc/lib/Xi/XGetVers.c xc/lib/Xi/XGetVers.c
---- xc/lib/Xi/XGetVers.c 2002-10-16 01:37:29.000000000 +0100
-+++ xc/lib/Xi/XGetVers.c 2003-06-24 18:25:10.000000000 +0100
-@@ -71,12 +71,31 @@
- char *name;
- #endif
- {
-+ XExtensionVersion *ext;
-+
-+ LockDisplay (dpy);
-+ ext = _XiGetExtensionVersion (dpy, name);
-+ UnlockDisplay (dpy);
-+ SyncHandle();
-+ return (ext);
-+ }
-+
-+XExtensionVersion
-+#if NeedFunctionPrototypes
-+*_XiGetExtensionVersion (
-+ register Display *dpy,
-+ _Xconst char *name)
-+#else
-+*_XiGetExtensionVersion (dpy, name)
-+ register Display *dpy;
-+ char *name;
-+#endif
-+ {
- xGetExtensionVersionReq *req;
- xGetExtensionVersionReply rep;
- XExtensionVersion *ext;
- XExtDisplayInfo *info = XInput_find_display (dpy);
-
-- LockDisplay (dpy);
- if (_XiCheckExtInit(dpy, Dont_Check) == -1)
- return ((XExtensionVersion *) NoSuchExtension);
-
-@@ -89,8 +108,6 @@
-
- if (! _XReply (dpy, (xReply *) &rep, 0, xTrue))
- {
-- UnlockDisplay(dpy);
-- SyncHandle();
- return (XExtensionVersion *) NULL;
- }
- ext = (XExtensionVersion *) Xmalloc (sizeof (XExtensionVersion));
-@@ -103,8 +120,6 @@
- ext->minor_version = rep.minor_version;
- }
- }
-- UnlockDisplay(dpy);
-- SyncHandle();
- return (ext);
- }
-
-diff -urN xc/lib/Xi/XIint.h xc/lib/Xi/XIint.h
---- xc/lib/Xi/XIint.h 2001-08-01 01:44:39.000000000 +0100
-+++ xc/lib/Xi/XIint.h 2003-06-24 00:09:49.000000000 +0100
-@@ -21,4 +21,11 @@
- #endif
- );
-
-+extern XExtensionVersion * _XiGetExtensionVersion(
-+#if NeedFunctionPrototypes
-+ Display*,
-+ _Xconst char*
-+#endif
-+);
-+
- #endif
Reply to: