diff options
author | Volker Lendecke <vl@samba.org> | 2011-04-22 09:48:10 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2011-04-22 10:06:36 +0200 |
commit | f9e3af71d391027de353f0240f70e425e766c0e5 (patch) | |
tree | c28888fc88b61947c3b6c65ab3d5b8d8bee57a9c /source3 | |
parent | 018595e2587b5b5dd90bf318a1cf8b675e47b66b (diff) | |
download | samba-f9e3af71d391027de353f0240f70e425e766c0e5.tar.gz samba-f9e3af71d391027de353f0240f70e425e766c0e5.tar.bz2 samba-f9e3af71d391027de353f0240f70e425e766c0e5.zip |
s3: Fix Coverity ID 2336, NULL_RETURNS
Diffstat (limited to 'source3')
-rw-r--r-- | source3/libads/ldap.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source3/libads/ldap.c b/source3/libads/ldap.c index 3ce7a7e869..90c645c44a 100644 --- a/source3/libads/ldap.c +++ b/source3/libads/ldap.c @@ -3502,6 +3502,10 @@ ADS_STATUS ads_leave_realm(ADS_STRUCT *ads, const char *hostname) } hostnameDN = ads_get_dn(ads, talloc_tos(), (LDAPMessage *)msg); + if (hostnameDN == NULL) { + SAFE_FREE(host); + return ADS_ERROR_SYSTEM(ENOENT); + } rc = ldap_delete_ext_s(ads->ldap.ld, hostnameDN, pldap_control, NULL); if (rc) { |