summaryrefslogtreecommitdiff
path: root/libcli/auth/netlogon_creds_cli.c
diff options
context:
space:
mode:
Diffstat (limited to 'libcli/auth/netlogon_creds_cli.c')
-rw-r--r--libcli/auth/netlogon_creds_cli.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/libcli/auth/netlogon_creds_cli.c b/libcli/auth/netlogon_creds_cli.c
index f1aa8d03ca5..c3b302addc4 100644
--- a/libcli/auth/netlogon_creds_cli.c
+++ b/libcli/auth/netlogon_creds_cli.c
@@ -635,6 +635,14 @@ NTSTATUS netlogon_creds_cli_store(struct netlogon_creds_cli_context *context,
return status;
}
+static NTSTATUS netlogon_creds_cli_delete_internal(
+ struct netlogon_creds_cli_context *context)
+{
+ NTSTATUS status;
+ status = dbwrap_delete(context->db.ctx, context->db.key_data);
+ return status;
+}
+
NTSTATUS netlogon_creds_cli_delete(struct netlogon_creds_cli_context *context,
struct netlogon_creds_CredentialState *creds)
{
@@ -654,13 +662,8 @@ NTSTATUS netlogon_creds_cli_delete(struct netlogon_creds_cli_context *context,
return NT_STATUS_INVALID_PAGE_PROTECTION;
}
- status = dbwrap_delete(context->db.ctx,
- context->db.key_data);
- if (!NT_STATUS_IS_OK(status)) {
- return status;
- }
-
- return NT_STATUS_OK;
+ status = netlogon_creds_cli_delete_internal(context);
+ return status;
}
struct netlogon_creds_cli_lock_state {