Blame autofs-5.0.4-fix-rpc-fd-leak.patch
|
Ian Kent |
a347ae |
autofs-5.0.4 - fix rpc fd leak
|
|
Ian Kent |
a347ae |
|
|
Ian Kent |
a347ae |
From: Ian Kent <raven@themaw.net>
|
|
Ian Kent |
a347ae |
|
|
Ian Kent |
a347ae |
Recent changes which introduced the ability to handle to cope with
|
|
Ian Kent |
a347ae |
IPv6 addresses causes a file descriptor leak in the RPC library.
|
|
Ian Kent |
a347ae |
---
|
|
Ian Kent |
a347ae |
|
|
Ian Kent |
a347ae |
CHANGELOG | 1 +
|
|
Ian Kent |
a347ae |
lib/rpc_subs.c | 11 -----------
|
|
Ian Kent |
a347ae |
2 files changed, 1 insertions(+), 11 deletions(-)
|
|
Ian Kent |
a347ae |
|
|
Ian Kent |
a347ae |
|
|
Ian Kent |
a347ae |
diff --git a/CHANGELOG b/CHANGELOG
|
|
Ian Kent |
a347ae |
index 3fd97d3..9edb113 100644
|
|
Ian Kent |
a347ae |
--- a/CHANGELOG
|
|
Ian Kent |
a347ae |
+++ b/CHANGELOG
|
|
Ian Kent |
a347ae |
@@ -56,6 +56,7 @@
|
|
Ian Kent |
a347ae |
- fix double free in sasl_bind().
|
|
Ian Kent |
a347ae |
- mannual umount recovery fixes.
|
|
Ian Kent |
a347ae |
- fix map type info parse error.
|
|
Ian Kent |
a347ae |
+- fix an RPC fd leak.
|
|
Ian Kent |
a347ae |
|
|
Ian Kent |
a347ae |
4/11/2008 autofs-5.0.4
|
|
Ian Kent |
a347ae |
-----------------------
|
|
Ian Kent |
a347ae |
diff --git a/lib/rpc_subs.c b/lib/rpc_subs.c
|
|
Ian Kent |
a347ae |
index d034b29..cafc775 100644
|
|
Ian Kent |
a347ae |
--- a/lib/rpc_subs.c
|
|
Ian Kent |
a347ae |
+++ b/lib/rpc_subs.c
|
|
Ian Kent |
a347ae |
@@ -253,17 +253,6 @@ static CLIENT *rpc_do_create_client(struct sockaddr *addr, struct conn_info *inf
|
|
Ian Kent |
a347ae |
return NULL;
|
|
Ian Kent |
a347ae |
}
|
|
Ian Kent |
a347ae |
|
|
Ian Kent |
a347ae |
- if (!info->client) {
|
|
Ian Kent |
a347ae |
- *fd = open_sock(addr->sa_family, type, proto);
|
|
Ian Kent |
a347ae |
- if (*fd < 0)
|
|
Ian Kent |
a347ae |
- return NULL;
|
|
Ian Kent |
a347ae |
-
|
|
Ian Kent |
a347ae |
- if (bind(*fd, laddr, slen) < 0) {
|
|
Ian Kent |
a347ae |
- close(*fd);
|
|
Ian Kent |
a347ae |
- return NULL;
|
|
Ian Kent |
a347ae |
- }
|
|
Ian Kent |
a347ae |
- }
|
|
Ian Kent |
a347ae |
-
|
|
Ian Kent |
a347ae |
switch (info->proto->p_proto) {
|
|
Ian Kent |
a347ae |
case IPPROTO_UDP:
|
|
Ian Kent |
a347ae |
if (!info->client) {
|