return APR_EINVAL;
}
rv = dup2(old_file->filedes, (*new_file)->filedes);
-+ if (!(old_file->flags & APR_INHERIT)) {
++ if (!(old_file->flags & (APR_FILE_NOCLEANUP|APR_INHERIT))) {
+ fdflags = fcntl((*new_file)->filedes, F_GETFD);
+ if (fdflags == -1)
+ return errno;
diff -urN apr-1.3.3.org/poll/unix/epoll.c apr-1.3.3/poll/unix/epoll.c
--- apr-1.3.3.org/poll/unix/epoll.c 2008-04-13 13:37:52.000000000 +0200
+++ apr-1.3.3/poll/unix/epoll.c 2009-02-23 08:20:07.663209400 +0100
-@@ -91,7 +91,7 @@
- apr_uint32_t flags)
- {
+@@ -93,7 +93,7 @@
+ #if APR_HAS_THREADS
apr_status_t rv;
+ #endif
- int fd;
+ int fd, fdflags;