]> granicus.if.org Git - apache/commitdiff
follow up r1601943:
authorTakashi Sato <takashi@apache.org>
Wed, 25 Jun 2014 09:42:41 +0000 (09:42 +0000)
committerTakashi Sato <takashi@apache.org>
Wed, 25 Jun 2014 09:42:41 +0000 (09:42 +0000)
Each apr_pollset_poll modified *out_pfd, so we need to copy it.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1605307 13f79535-47bb-0310-9956-ffa450edef68

server/mpm/event/event.c

index 2d96189fcb2ab937eb8d5e3c2387c74cc9bb318d..ae49c01ca15c17b38f04e2f6d67aa9ce89297b8f 100644 (file)
@@ -1969,10 +1969,12 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
 
                 /* We only signal once per N sockets with this baton */
                 if (!(baton->signaled)) { 
+                    apr_pollfd_t *newpfd = apr_palloc(out_pfd->p, sizeof(apr_pollfd_t));
                     baton->signaled = 1;
+                    *newpfd = *out_pfd;
                     te = event_get_timer_event(-1 /* fake timer */, 
                                                socket_callback_wrapper, 
-                                               (apr_pollfd_t *)out_pfd,
+                                               newpfd,
                                                0, /* don't insert it */
                                                NULL /* no associated socket callback */);
                     /* remove other sockets in my set */