summaryrefslogtreecommitdiff
path: root/source3/winbindd
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2012-07-18 05:01:31 +0930
committerRusty Russell <rusty@rustcorp.com.au>2012-07-18 05:01:31 +0930
commit2314c606297218b8e16bb42b181c1ea175cf710a (patch)
tree6278d3b19d4dd156e400cbaf3f236b20a738da75 /source3/winbindd
parent7a6591037b22773c03a7592230f33832b0775237 (diff)
downloadsamba-2314c606297218b8e16bb42b181c1ea175cf710a.tar.gz
samba-2314c606297218b8e16bb42b181c1ea175cf710a.tar.bz2
samba-2314c606297218b8e16bb42b181c1ea175cf710a.zip
source3/winbindd/winbindd_util.c: fix stackframe leak
winbindd_can_contact_domain() doesn't always free its stackframe. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'source3/winbindd')
-rw-r--r--source3/winbindd/winbindd_util.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source3/winbindd/winbindd_util.c b/source3/winbindd/winbindd_util.c
index ffc9115ad3..162cdf22e1 100644
--- a/source3/winbindd/winbindd_util.c
+++ b/source3/winbindd/winbindd_util.c
@@ -1173,7 +1173,8 @@ bool winbindd_can_contact_domain(struct winbindd_domain *domain)
/* We can contact the domain if it is our primary domain */
if (domain->primary) {
- return true;
+ ret = true;
+ goto done;
}
/* Trust the TDC cache and not the winbindd_domain flags */
@@ -1181,7 +1182,8 @@ bool winbindd_can_contact_domain(struct winbindd_domain *domain)
if ((tdc = wcache_tdc_fetch_domain(frame, domain->name)) == NULL) {
DEBUG(10,("winbindd_can_contact_domain: %s not found in cache\n",
domain->name));
- return false;
+ ret = false;
+ goto done;
}
/* Can always contact a domain that is in out forest */