The Samba-Bugzilla – Attachment 4799 Details for
Bug 6785
Only ever handle one event after a select call
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for 3.3
0001-s3-winbind-Only-ever-handle-one-event-after-a-selec.patch (text/plain), 1.56 KB, created by
Volker Lendecke
on 2009-10-07 09:01:45 UTC
(
hide
)
Description:
Patch for 3.3
Filename:
MIME Type:
Creator:
Volker Lendecke
Created:
2009-10-07 09:01:45 UTC
Size:
1.56 KB
patch
obsolete
>From 46e05079c5cdf2bd0a317481ad654d2464a5bbc9 Mon Sep 17 00:00:00 2001 >From: Volker Lendecke <vl@samba.org> >Date: Wed, 7 Oct 2009 14:06:53 +0200 >Subject: [PATCH] s3:winbind: Only ever handle one event after a select call > >While handling an fd event, the situation with other fds can change. I've just >seen a winbind stuck in the accept() call on the privileged pipe. I can only >imagine this happen because under high load we first handled other requests and >meanwhile the client on the privileged pipe went away. >--- > source3/winbindd/winbindd.c | 12 +++++++++--- > 1 files changed, 9 insertions(+), 3 deletions(-) > >diff --git a/source3/winbindd/winbindd.c b/source3/winbindd/winbindd.c >index 33b35e0..260dfdd 100644 >--- a/source3/winbindd/winbindd.c >+++ b/source3/winbindd/winbindd.c >@@ -1035,7 +1035,9 @@ static void process_loop(void) > int maxfd = 0, selret; > struct timeval timeout, ev_timeout; > >- run_events(winbind_event_context(), 0, NULL, NULL); >+ if (run_events(winbind_event_context(), 0, NULL, NULL)) { >+ return; >+ } > > /* Initialise fd lists for select() */ > >@@ -1089,7 +1091,9 @@ static void process_loop(void) > > /* selret > 0 */ > >- run_events(winbind_event_context(), selret, &r_fds, &w_fds); >+ if (run_events(winbind_event_context(), selret, &r_fds, &w_fds)) { >+ return; >+ } > > ev = fd_events; > while (ev != NULL) { >@@ -1099,8 +1103,10 @@ static void process_loop(void) > flags |= EVENT_FD_READ; > if (FD_ISSET(ev->fd, &w_fds)) > flags |= EVENT_FD_WRITE; >- if (flags) >+ if (flags) { > ev->handler(ev, flags); >+ return; >+ } > ev = next; > } > >-- >1.6.2.1 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Flags:
metze
:
review+
Actions:
View
Attachments on
bug 6785
:
4798
|
4799
|
4812