6585644 xscreensaver can cause keypress event loop between itself and xscreensaver-lock
authorMahmood Ali <Mahmood.Ali@Sun.COM>
Thu, 28 Feb 2008 00:23:57 -0800
changeset 342 04234c9465e5
parent 341 0a1eb61fd56e
child 343 fed7f2b33d35
6585644 xscreensaver can cause keypress event loop between itself and xscreensaver-lock
open-src/app/xscreensaver/Makefile
open-src/app/xscreensaver/notice_events.patch
--- a/open-src/app/xscreensaver/Makefile	Thu Feb 28 17:02:09 2008 -0800
+++ b/open-src/app/xscreensaver/Makefile	Thu Feb 28 00:23:57 2008 -0800
@@ -30,7 +30,7 @@
 # or other dealings in this Software without prior written authorization
 # of the copyright holder.
 #
-# @(#)Makefile	1.86	08/02/27
+# @(#)Makefile	1.87	08/02/27
 #
 
 PWD:sh=pwd
@@ -81,7 +81,8 @@
 	bug-6610282.patch \
 	bug-6475285.patch \
         XScr.ad.lockTimeout.patch \
-	bug-6583181.patch
+	bug-6583181.patch \
+        notice_events.patch
 
 # Directory created by unpacking source
 SOURCE_DIR=$(BUILD_DIR)/xscreensaver-$(XSCREENSAVER_VERS)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/open-src/app/xscreensaver/notice_events.patch	Thu Feb 28 00:23:57 2008 -0800
@@ -0,0 +1,48 @@
+/*
+ * Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, and/or sell copies of the Software, and to permit persons
+ * to whom the Software is furnished to do so, provided that the above
+ * copyright notice(s) and this permission notice appear in all copies of
+ * the Software and that both the above copyright notice(s) and this
+ * permission notice appear in supporting documentation.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
+ * OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
+ * HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL
+ * INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING
+ * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
+ * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ *
+ * Except as contained in this notice, the name of a copyright holder
+ * shall not be used in advertising or otherwise to promote the sale, use
+ * or other dealings in this Software without prior written authorization
+ * of the copyright holder.
+ *
+ */
+
+Fix for: 6585644 xscreensaver can cause KeyPress event loop between itself and xscreensaver-lock.
+
+--- driver/timers.c	Wed Feb 27 22:52:08 2008
++++ driver/timers.c	Wed Feb 27 22:57:43 2008
+@@ -136,6 +136,13 @@
+   unsigned int nkids;
+   int screen_no;
+ 
++  if ((si->pw_data->got_windowid) && (window == si->passwd_dialog))
++   {
++    if (p->verbose_p)
++     fprintf (stderr, "--> notice_events() breaking out of loop!\n");
++    return;
++   }
++
+   if (XtWindowToWidget (si->dpy, window))
+     /* If it's one of ours, don't mess up its event mask. */
+     return;