The Samba-Bugzilla – Attachment 5965 Details for
Bug 7684
fd leak in libwbclient.so
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for 3.5
0001-libwbclient-Fix-a-fd-leak-at-dlclose-time.patch (text/plain), 1011 bytes, created by
Volker Lendecke
on 2010-09-16 12:09:22 UTC
(
hide
)
Description:
Patch for 3.5
Filename:
MIME Type:
Creator:
Volker Lendecke
Created:
2010-09-16 12:09:22 UTC
Size:
1011 bytes
patch
obsolete
>From 72adaa0e1bb5ede7e55c20d7ba6b05b299c848b1 Mon Sep 17 00:00:00 2001 >From: Volker Lendecke <vl@samba.org> >Date: Mon, 10 May 2010 12:05:01 +0200 >Subject: [PATCH] libwbclient: Fix a fd-leak at dlclose-time > >__attribute__((destructor)) makes winbind_close_sock() being called at >dlclose() time. > >Found while testing apache on Linux with mod_auth_pam. > >Other platforms will have to find a different fix. One possibility would be to >always close the socket after each operation, but this badly sucks >performance-wise. >--- > nsswitch/wb_common.c | 3 +++ > 1 files changed, 3 insertions(+), 0 deletions(-) > >diff --git a/nsswitch/wb_common.c b/nsswitch/wb_common.c >index d0dfcb8..b7fafc3 100644 >--- a/nsswitch/wb_common.c >+++ b/nsswitch/wb_common.c >@@ -61,6 +61,9 @@ static void init_response(struct winbindd_response *response) > > /* Close established socket */ > >+#if HAVE_FUNCTION_ATTRIBUTE_DESTRUCTOR >+__attribute__((destructor)) >+#endif > void winbind_close_sock(void) > { > if (winbindd_fd != -1) { >-- >1.7.0.4 >
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:
jra
:
review+
Actions:
View
Attachments on
bug 7684
: 5965