File cups-1.3.9-CVE-2010-0302.patch of Package cups

--- scheduler/select.c.orig	2010-02-09 14:04:03.000000000 +0100
+++ scheduler/select.c	2010-02-09 14:52:12.000000000 +0100
@@ -483,7 +483,8 @@ cupsdDoSelect(long timeout)		/* I - Time
       (*(fdptr->read_cb))(fdptr->data);
     }
 
-    if (fdptr->use > 1 && fdptr->write_cb && event->filter == EVFILT_WRITE)
+    if (fdptr->use > 1 && fdptr->write_cb && event->filter == EVFILT_WRITE &&
+        !cupsArrayFind(cupsd_inactive_fds, fdptr))
     {
       cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdDoSelect: Write on fd %d...",
 	              fdptr->fd);
@@ -543,7 +544,9 @@ cupsdDoSelect(long timeout)		/* I - Time
 	  (*(fdptr->read_cb))(fdptr->data);
 	}
 
-	if (fdptr->use > 1 && fdptr->write_cb && (event->events & (EPOLLOUT | EPOLLERR | EPOLLHUP)))
+	if (fdptr->use > 1 && fdptr->write_cb &&
+            (event->events & (EPOLLOUT | EPOLLERR | EPOLLHUP)) &&
+            !cupsArrayFind(cupsd_inactive_fds, fdptr))
 	{
 	  cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdDoSelect: Write on fd %d...",
 	        	  fdptr->fd);
openSUSE Build Service is sponsored by