The Samba-Bugzilla – Attachment 4828 Details for
Bug 6796
Deleting an event context on shutdown can cause smbd to crash.
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
git-am format patch for 3.4.3.
0001-Fix-bug-6796-Deleting-an-event-context-on-shutdown.patch (text/plain), 1.30 KB, created by
Jeremy Allison
on 2009-10-09 14:53:08 UTC
(
hide
)
Description:
git-am format patch for 3.4.3.
Filename:
MIME Type:
Creator:
Jeremy Allison
Created:
2009-10-09 14:53:08 UTC
Size:
1.30 KB
patch
obsolete
>From 654fa181aae0f88d6bc03fca1c5fdd7098465291 Mon Sep 17 00:00:00 2001 >From: Jeremy Allison <jra@samba.org> >Date: Fri, 9 Oct 2009 12:50:26 -0700 >Subject: [PATCH] Fix bug 6796 - Deleting an event context on shutdown can cause smbd to crash. > Sync's tevent signal code with 3.5.x tree. Protects against ev pointer being NULL. > Jeremy > >--- > lib/tevent/tevent_signal.c | 10 ++-------- > 1 files changed, 2 insertions(+), 8 deletions(-) > >diff --git a/lib/tevent/tevent_signal.c b/lib/tevent/tevent_signal.c >index 0ca2a27..ab170a6 100644 >--- a/lib/tevent/tevent_signal.c >+++ b/lib/tevent/tevent_signal.c >@@ -90,18 +90,12 @@ static void tevent_common_signal_handler(int signum) > SIG_INCREMENT(sig_state->signal_count[signum]); > SIG_INCREMENT(sig_state->got_signal); > >- if (sig_state->sig_handlers[signum] != NULL) { >- ev = sig_state->sig_handlers[signum]->se->event_ctx; >- /* doesn't matter if this pipe overflows */ >- res = write(ev->pipe_fds[1], &c, 1); >- } >- > /* Write to each unique event context. */ > for (sl = sig_state->sig_handlers[signum]; sl; sl = sl->next) { >- if (sl->se->event_ctx != ev) { >+ if (sl->se->event_ctx && sl->se->event_ctx != ev) { >+ ev = sl->se->event_ctx; > /* doesn't matter if this pipe overflows */ > res = write(ev->pipe_fds[1], &c, 1); >- ev = sl->se->event_ctx; > } > } > >-- >1.5.4.3 >
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 6796
: 4828