mirror of
https://github.com/samba-team/samba.git
synced 2025-02-03 13:47:25 +03:00
s4:libcli/ldap: ldap4_new_connection() requires a valid lp_ctx
Otherwise we'll crash in a lot of places later. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> (cherry picked from commit 8007569e9f7d374456a3fbd172a905173462eb5f)
This commit is contained in:
parent
52fc65513f
commit
07e707c4de
@ -65,6 +65,10 @@ _PUBLIC_ struct ldap_connection *ldap4_new_connection(TALLOC_CTX *mem_ctx,
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (lp_ctx == NULL) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
conn = talloc_zero(mem_ctx, struct ldap_connection);
|
||||
if (conn == NULL) {
|
||||
return NULL;
|
||||
|
Loading…
x
Reference in New Issue
Block a user