1f529d9f7e
#557775). - Added comments for all sources and patches.
25 lines
1.1 KiB
Diff
25 lines
1.1 KiB
Diff
diff -up cups-1.4.2/scheduler/select.c.CVE-2010-0302 cups-1.4.2/scheduler/select.c
|
|
--- cups-1.4.2/scheduler/select.c.CVE-2010-0302 2010-03-05 10:37:49.990476887 +0000
|
|
+++ cups-1.4.2/scheduler/select.c 2010-03-05 10:38:01.803478081 +0000
|
|
@@ -454,7 +454,8 @@ cupsdDoSelect(long timeout) /* I - Time
|
|
if (fdptr->read_cb && event->filter == EVFILT_READ)
|
|
(*(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))
|
|
(*(fdptr->write_cb))(fdptr->data);
|
|
|
|
release_fd(fdptr);
|
|
@@ -499,7 +500,9 @@ cupsdDoSelect(long timeout) /* I - Time
|
|
if (fdptr->read_cb && (event->events & (EPOLLIN | EPOLLERR | EPOLLHUP)))
|
|
(*(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))
|
|
(*(fdptr->write_cb))(fdptr->data);
|
|
|
|
release_fd(fdptr);
|