The Samba-Bugzilla – Attachment 13766 Details for
Bug 13130
smbd on disk file corruption bug under heavy threaded load.
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Instrumentation of tevent that allowed Volker to find the bug.
instrumentation.patch.txt (text/plain), 1.14 KB, created by
Jeremy Allison
on 2017-11-10 22:10:31 UTC
(
hide
)
Description:
Instrumentation of tevent that allowed Volker to find the bug.
Filename:
MIME Type:
Creator:
Jeremy Allison
Created:
2017-11-10 22:10:31 UTC
Size:
1.14 KB
patch
obsolete
>From e380f8da6d019c58add179a5b9354e37088467d0 Mon Sep 17 00:00:00 2001 >From: Volker Lendecke <vl@samba.org> >Date: Fri, 10 Nov 2017 11:01:04 +0100 >Subject: [PATCH] check that eventfd is not a real file > >Signed-off-by: Volker Lendecke <vl@samba.org> >--- > lib/tevent/tevent.c | 15 +++++++++++++++ > 1 file changed, 15 insertions(+) > >diff --git a/lib/tevent/tevent.c b/lib/tevent/tevent.c >index a2d2003cbf4..da46d93ede0 100644 >--- a/lib/tevent/tevent.c >+++ b/lib/tevent/tevent.c >@@ -69,6 +69,7 @@ > #ifdef HAVE_EVENTFD > #include <sys/eventfd.h> > #endif >+#include <assert.h> > > static void tevent_abort(struct tevent_context *ev, const char *reason); > >@@ -953,6 +954,13 @@ int tevent_common_wakeup_fd(int fd) > { > ssize_t ret; > >+ { >+ struct stat st; >+ int statret = fstat(fd, &st); >+ assert(statret == 0); >+ assert((st.st_mode & S_IFMT) == 0); >+ } >+ > do { > #ifdef HAVE_EVENTFD > uint64_t val = 1; >@@ -963,6 +971,13 @@ int tevent_common_wakeup_fd(int fd) > #endif > } while ((ret == -1) && (errno == EINTR)); > >+ { >+ struct stat st; >+ int statret = fstat(fd, &st); >+ assert(statret == 0); >+ assert((st.st_mode & S_IFMT) == 0); >+ } >+ > return 0; > } > >-- >2.11.0 >
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
Actions:
View
Attachments on
bug 13130
: 13766 |
13767
|
13768
|
13769
|
13777
|
13778