rpms/nspluginwrapper/devel nspluginwrapper-0.9.91.5-sleep.patch, NONE, 1.1 nspluginwrapper.spec, 1.43, 1.44

Martin Stransky (stransky) fedora-extras-commits at redhat.com
Thu Mar 6 13:18:59 UTC 2008


Author: stransky

Update of /cvs/pkgs/rpms/nspluginwrapper/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv21827

Modified Files:
	nspluginwrapper.spec 
Added Files:
	nspluginwrapper-0.9.91.5-sleep.patch 
Log Message:
* Thu Mar 06 2008 Martin Stransky <stransky at redhat.com> 0.9.91.5-24
- added experimental patch for #426968 - nspluginwrapper wakes up too much



nspluginwrapper-0.9.91.5-sleep.patch:

--- NEW FILE nspluginwrapper-0.9.91.5-sleep.patch ---
diff -up nspluginwrapper-0.9.91.5/src/npw-viewer.c.old nspluginwrapper-0.9.91.5/src/npw-viewer.c
--- nspluginwrapper-0.9.91.5/src/npw-viewer.c.old	2008-03-06 13:51:03.000000000 +0100
+++ nspluginwrapper-0.9.91.5/src/npw-viewer.c	2008-03-06 14:00:05.000000000 +0100
@@ -3039,14 +3039,14 @@ static GPollFD xt_event_poll_fd;
 static gboolean xt_event_prepare(GSource *source, gint *timeout)
 {
   int mask = XtAppPending(x_app_context);
-  return mask & XtIMXEvent;
+  return mask;
 }
 
 static gboolean xt_event_check(GSource *source)
 {
   if (xt_event_poll_fd.revents & G_IO_IN) {
 	int mask = XtAppPending(x_app_context);
-	if (mask & XtIMXEvent)
+	if (mask)
 	  return TRUE;
   }
   return FALSE;
@@ -3057,9 +3057,9 @@ static gboolean xt_event_dispatch(GSourc
   int i;
   for (i = 0; i < 5; i++) {
 	int mask = XtAppPending(x_app_context);
-	if ((mask & XtIMXEvent) == 0)
+	if ((mask) == 0)
 	  break;
-	XtAppProcessEvent(x_app_context, XtIMXEvent);
+	XtAppProcessEvent(x_app_context, XtIMAll);
   }
   return TRUE;
 }
@@ -3073,17 +3073,6 @@ static GSourceFuncs xt_event_funcs = {
   (GSourceDummyMarshal)NULL
 };
 
-static gboolean xt_event_polling_timer_callback(gpointer user_data)
-{
-  int i;
-  for (i = 0; i < 5; i++) {
-	if ((XtAppPending(x_app_context) & (XtIMAll & ~XtIMXEvent)) == 0)
-	  break;
-	XtAppProcessEvent(x_app_context, XtIMAll & ~XtIMXEvent);
-  }
-  return TRUE;
-}
-
 // RPC events
 static GPollFD rpc_event_poll_fd;
 
@@ -3208,10 +3197,6 @@ static int do_main(int argc, char **argv
   xt_event_poll_fd.revents = 0;
   g_source_add_poll(xt_source, &xt_event_poll_fd);
 
-  gint xt_polling_timer_id = g_timeout_add(25,
-										   xt_event_polling_timer_callback,
-										   NULL);
-
   // Initialize RPC events listener
   GSource *rpc_source = g_source_new(&rpc_event_funcs, sizeof(GSource));
   if (rpc_source == NULL) {
@@ -3232,7 +3217,6 @@ static int do_main(int argc, char **argv
   gtk_main();
   D(bug("--- EXIT ---\n"));
 
-  g_source_remove(xt_polling_timer_id);
   g_source_destroy(rpc_source);
   g_source_destroy(xt_source);
 


Index: nspluginwrapper.spec
===================================================================
RCS file: /cvs/pkgs/rpms/nspluginwrapper/devel/nspluginwrapper.spec,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -r1.43 -r1.44
--- nspluginwrapper.spec	26 Feb 2008 12:01:02 -0000	1.43
+++ nspluginwrapper.spec	6 Mar 2008 13:18:07 -0000	1.44
@@ -70,7 +70,7 @@
 Summary:	A compatibility layer for Netscape 4 plugins
 Name:		nspluginwrapper
 Version:	0.9.91.5
-Release:	23%{?dist}
+Release:	24%{?dist}
 Source0:	%{name}-%{version}%{?svndate:-%{svndate}}.tar.bz2
 Source1:        %{plugin_config_name}.tar.gz 
 Source2:        plugin-config.sh.in
@@ -83,6 +83,7 @@
 Patch6:         nspluginwrapper-0.9.91.5-xulrunner.patch
 Patch7:         nspluginwrapper-0.9.91.5-npviewer-gthread.patch
 Patch8:         nspluginwrapper-0.9.91.5-shutdown.patch
+Patch9:         nspluginwrapper-0.9.91.5-sleep.patch
 Patch10:        plugin-config-setuid.patch
 License:	GPL
 Group:		Networking/WWW
@@ -115,6 +116,7 @@
 %patch6 -p1 -b .xl
 %patch7 -p1 -b .thread
 %patch8 -p1 -b .shutdown
+%patch9 -p1 -b .sleep
 
 pushd %plugin_config_name
 %patch10 -p2
@@ -237,6 +239,9 @@
 %{_sysconfdir}/sysconfig/%{name}
 
 %changelog
+* Thu Mar 06 2008 Martin Stransky <stransky at redhat.com> 0.9.91.5-24
+- added experimental patch for #426968 - nspluginwrapper wakes up too much
+
 * Tue Feb 26 2008 Martin Stransky <stransky at redhat.com> 0.9.91.5-23
 - merged exclude patch with main tarball
 - fixed #431095 - Typo in mozilla-plugin-config verbose output




More information about the fedora-extras-commits mailing list