summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2019-03-21 13:54:10 +0100
committerJule Anger <janger@samba.org>2023-04-05 10:40:13 +0000
commitbbd1f56b78cfd0a644016db88ee0eb2a4b2dbc3d (patch)
treeb5936c1db8f9e83a3275b58650df5a821736d50a
parent00909630b0d609f694ee078562d59dd43cdbdd60 (diff)
downloadsamba-bbd1f56b78cfd0a644016db88ee0eb2a4b2dbc3d.tar.gz
idmap_hash: remove unused error checks
id_map_ptrs_init() is used in the callers in order to set everything up as expected. Other backends also just trust the caller. BUG: https://bugzilla.samba.org/show_bug.cgi?id=15319 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> (cherry picked from commit 2cfcff3101fce94b365eccde114432dfa980bbd0)
-rw-r--r--source3/winbindd/idmap_hash/idmap_hash.c17
1 files changed, 0 insertions, 17 deletions
diff --git a/source3/winbindd/idmap_hash/idmap_hash.c b/source3/winbindd/idmap_hash/idmap_hash.c
index 99341bc6fab..ce324bfd240 100644
--- a/source3/winbindd/idmap_hash/idmap_hash.c
+++ b/source3/winbindd/idmap_hash/idmap_hash.c
@@ -199,11 +199,6 @@ static NTSTATUS unixids_to_sids(struct idmap_domain *dom,
NTSTATUS nt_status = NT_STATUS_UNSUCCESSFUL;
int i;
- if (!ids) {
- nt_status = NT_STATUS_INVALID_PARAMETER;
- BAIL_ON_NTSTATUS_ERROR(nt_status);
- }
-
/* initialize the status to avoid suprise */
for (i = 0; ids[i]; i++) {
ids[i]->status = ID_UNKNOWN;
@@ -219,13 +214,6 @@ static NTSTATUS unixids_to_sids(struct idmap_domain *dom,
separate_hashes(ids[i]->xid.id, &h_domain, &h_rid);
- /* Make sure the caller allocated memor for us */
-
- if (!ids[i]->sid) {
- nt_status = NT_STATUS_INVALID_PARAMETER;
- BAIL_ON_NTSTATUS_ERROR(nt_status);
- }
-
/* If the domain hash doesn't find a SID in the table,
skip it */
@@ -250,11 +238,6 @@ static NTSTATUS sids_to_unixids(struct idmap_domain *dom,
NTSTATUS nt_status = NT_STATUS_UNSUCCESSFUL;
int i;
- if (!ids) {
- nt_status = NT_STATUS_INVALID_PARAMETER;
- BAIL_ON_NTSTATUS_ERROR(nt_status);
- }
-
/* initialize the status to avoid suprise */
for (i = 0; ids[i]; i++) {
ids[i]->status = ID_UNKNOWN;