rpms/at-spi/devel at-spi-1.17.2-fix-some-deadlock-issues.patch, NONE, 1.1 at-spi.spec, 1.63, 1.64

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Thu Mar 8 16:00:48 UTC 2007


Author: rstrode

Update of /cvs/dist/rpms/at-spi/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv27227

Modified Files:
	at-spi.spec 
Added Files:
	at-spi-1.17.2-fix-some-deadlock-issues.patch 
Log Message:
- add a patch that might fix some deadlock issues (bug 329454)


at-spi-1.17.2-fix-some-deadlock-issues.patch:
 bridge.c |   33 +++++++++++++++++++++++++--------
 1 files changed, 25 insertions(+), 8 deletions(-)

--- NEW FILE at-spi-1.17.2-fix-some-deadlock-issues.patch ---
--- at-spi-1.17.2/atk-bridge/bridge.c
+++ at-spi-1.17.2/atk-bridge/bridge.c
@@ -46,6 +46,11 @@
 
 #define DBG(a,b) if(_dbg>=(a))b
 
+#define bridge_threads_leave() \
+  if (!during_init_shutdown) atk_misc_threads_leave(misc)
+#define bridge_threads_enter() \
+  if (!during_init_shutdown) atk_misc_threads_enter(misc)
+
 int _dbg = 0;
 static CORBA_Environment ev;
 static Accessibility_Registry registry = CORBA_OBJECT_NIL;
@@ -56,6 +61,7 @@
 static gint toplevels = 0;
 static gboolean exiting = FALSE;
 static AtkMisc *misc = NULL;
+static gboolean during_init_shutdown = TRUE;
 
 static guint atk_signal_text_changed;
 static guint atk_signal_children_changed;
@@ -171,6 +177,13 @@
   done = TRUE;
 }
 
+static gboolean
+post_init (void)
+{
+  during_init_shutdown = FALSE;
+  return FALSE;
+}
+
 static int
 atk_bridge_init (gint *argc, gchar **argv[])
 {
@@ -243,6 +256,8 @@
     {
       atk_bridge_initialized = FALSE;
     }
+  g_idle_add (post_init, NULL);
+
   return 0;
 }
 
@@ -311,11 +326,11 @@
 static void
 spi_atk_bridge_register_application (Accessibility_Registry registry)
 {
-  atk_misc_threads_leave (misc);
+  bridge_threads_leave ();
   Accessibility_Registry_registerApplication (spi_atk_bridge_get_registry (),
                                               BONOBO_OBJREF (this_app),
                                               &ev);
-  atk_misc_threads_enter (misc);
+  bridge_threads_enter ();
   if (ev._major != CORBA_NO_EXCEPTION)
     CORBA_exception_free (&ev);
 }
@@ -566,9 +581,9 @@
 deregister_application (BonoboObject *app)
 {
   Accessibility_Registry registry = spi_atk_bridge_get_registry ();
-  atk_misc_threads_leave (misc);
+  bridge_threads_leave ();
   Accessibility_Registry_deregisterApplication (registry, BONOBO_OBJREF (app), &ev);
-  atk_misc_threads_enter (misc);
+  bridge_threads_enter ();
 
   device_event_controller = bonobo_object_release_unref (device_event_controller, &ev);
   registry = bonobo_object_release_unref (registry, &ev);
@@ -593,6 +608,7 @@
       _exit (0);
     }
 
+  during_init_shutdown = TRUE;
   exiting = TRUE;
   /*
    * Check whether we still have windows which have not been deleted.
@@ -645,6 +661,7 @@
     {
       return;
     }
+  during_init_shutdown = TRUE;
   atk_bridge_initialized = FALSE;
   this_app = NULL;
 
@@ -688,10 +705,10 @@
   if (BONOBO_EX (&ev))
       registry_died = TRUE;
   else {
-      atk_misc_threads_leave (misc);   
+      bridge_threads_leave ();   
       Accessibility_Registry_notifyEvent (spi_atk_bridge_get_registry (), 
 					  &e, &ev);
-      atk_misc_threads_enter (misc);
+      bridge_threads_enter ();
   }
   if (BONOBO_EX (&ev))
     registry_died = TRUE;
@@ -760,10 +777,10 @@
   registry = spi_atk_bridge_get_registry ();
   if (!registry_died)
   {
-    atk_misc_threads_leave (misc); 
+    bridge_threads_leave (); 
     Accessibility_Registry_notifyEvent (registry, 
                                         &e, &ev);
-    atk_misc_threads_enter (misc);
+    bridge_threads_enter ();
 #ifdef SPI_BRIDGE_DEBUG
     if (ev._major != CORBA_NO_EXCEPTION)
         g_message ("error emitting event %s, (%d) %s",


Index: at-spi.spec
===================================================================
RCS file: /cvs/dist/rpms/at-spi/devel/at-spi.spec,v
retrieving revision 1.63
retrieving revision 1.64
diff -u -r1.63 -r1.64
--- at-spi.spec	28 Feb 2007 04:15:38 -0000	1.63
+++ at-spi.spec	8 Mar 2007 16:00:46 -0000	1.64
@@ -8,7 +8,7 @@
 Summary: Assistive Technology Service Provider Interface 
 Name: at-spi
 Version: 1.17.2
-Release: 1%{?dist}
+Release: 2%{?dist}
 URL: http://developer.gnome.org/projects/gap/
 Source0: http://ftp.gnome.org/pub/gnome/sources/at-spi/1.17/%{name}-%{version}.tar.bz2
 
@@ -36,6 +36,8 @@
 BuildRequires: libXevie-devel 
 BuildRequires: libXt-devel 
 
+Patch0: at-spi-1.17.2-fix-some-deadlock-issues.patch
+
 %description
 at-spi allows assistive technologies to access GTK-based
 applications. Essentially it exposes the internals of applications for
@@ -60,6 +62,7 @@
 
 %prep
 %setup -q
+%patch0 -p1 -b .fix-some-deadlock-issues
 
 %build
 %configure --disable-gtk-doc
@@ -67,7 +70,7 @@
 
 %install
 rm -rf $RPM_BUILD_ROOT
-%makeinstall
+make install DESTDIR=$RPM_BUILD_ROOT
 
 %find_lang at-spi
 
@@ -99,6 +102,9 @@
 %{_includedir}/* 
 
 %changelog
+* Thu Mar  8 2007 Ray Strode <rstrode at redhat.com> - 1.17.2-2
+- add a patch that might fix some deadlock issues (bug 329454)
+
 * Tue Feb 27 2007 Matthias Clasen <mclasen at redhat.com> - 1.17.2-1
 - Update to 1.17.2
 




More information about the fedora-cvs-commits mailing list