summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/libads/util.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source3/libads/util.c b/source3/libads/util.c
index af96c3e10a..72f5dee80c 100644
--- a/source3/libads/util.c
+++ b/source3/libads/util.c
@@ -64,6 +64,8 @@ ADS_STATUS ads_guess_service_principal(ADS_STRUCT *ads,
server_realm = SMB_STRDUP(ads->server.realm);
if (!server || !server_realm) {
+ SAFE_FREE(server);
+ SAFE_FREE(server_realm);
return ADS_ERROR(LDAP_NO_MEMORY);
}