netlogon_creds_cli_open_global_db() already contains the NULL check. Use that.
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
return NT_STATUS_NO_MEMORY;
}
- if (netlogon_creds_cli_global_db != NULL) {
- context->db.ctx = netlogon_creds_cli_global_db;
- *_context = context;
- TALLOC_FREE(frame);
- return NT_STATUS_OK;
- }
-
status = netlogon_creds_cli_open_global_db(lp_ctx);
if (!NT_STATUS_IS_OK(status)) {
TALLOC_FREE(context);