1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-22 13:34:15 +03:00

dsdb: Make argument order of dsdb_update_gmsa_{entry_,}keys() consistant with other uses

Other functions in this file are TALLOC_CTX, struct ldb_context *, not
the other way around.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jo Sutton <josutton@catalyst.net.nz>
This commit is contained in:
Andrew Bartlett 2024-04-23 16:17:04 +12:00
parent a9b3522f53
commit e04eb9bb17
4 changed files with 15 additions and 12 deletions

View File

@ -5755,7 +5755,7 @@ int dsdb_search(struct ldb_context *ldb,
* whenCreated
*/
ret = dsdb_update_gmsa_keys(ldb, tmp_ctx, res, &retry);
ret = dsdb_update_gmsa_keys(tmp_ctx, ldb, res, &retry);
if (ret) {
talloc_free(tmp_ctx);
return ret;

View File

@ -1529,8 +1529,8 @@ static bool dsdb_data_blobs_equal(const DATA_BLOB *d1, const DATA_BLOB *d2)
}
}
int dsdb_update_gmsa_entry_keys(struct ldb_context *ldb,
TALLOC_CTX *mem_ctx,
int dsdb_update_gmsa_entry_keys(TALLOC_CTX *mem_ctx,
struct ldb_context *ldb,
const struct gmsa_update *gmsa_update)
{
TALLOC_CTX *tmp_ctx = NULL;
@ -1650,8 +1650,8 @@ out:
return ret;
}
int dsdb_update_gmsa_keys(struct ldb_context *ldb,
TALLOC_CTX *mem_ctx,
int dsdb_update_gmsa_keys(TALLOC_CTX *mem_ctx,
struct ldb_context *ldb,
const struct ldb_result *res,
bool *retry_out)
{
@ -1750,7 +1750,9 @@ int dsdb_update_gmsa_keys(struct ldb_context *ldb,
continue;
}
ret = dsdb_update_gmsa_entry_keys(ldb, tmp_ctx, gmsa_update);
ret = dsdb_update_gmsa_entry_keys(tmp_ctx,
ldb,
gmsa_update);
if (ret) {
goto out;
}

View File

@ -118,12 +118,12 @@ int gmsa_recalculate_managed_pwd(TALLOC_CTX *mem_ctx,
struct gmsa_update **update_out,
struct gmsa_return_pwd *return_out);
int dsdb_update_gmsa_entry_keys(struct ldb_context *ldb,
TALLOC_CTX *mem_ctx,
int dsdb_update_gmsa_entry_keys(TALLOC_CTX *mem_ctx,
struct ldb_context *ldb,
const struct gmsa_update *gmsa_update);
int dsdb_update_gmsa_keys(struct ldb_context *ldb,
TALLOC_CTX *mem_ctx,
int dsdb_update_gmsa_keys(TALLOC_CTX *mem_ctx,
struct ldb_context *ldb,
const struct ldb_result *res,
bool *retry_out);

View File

@ -956,8 +956,9 @@ static NTSTATUS ldapsrv_SearchRequest(struct ldapsrv_call *call)
for (n = 0; n < len; ++n) {
int ret;
ret = dsdb_update_gmsa_entry_keys(
samdb, local_ctx, callback_ctx->updates[n]);
ret = dsdb_update_gmsa_entry_keys(local_ctx,
samdb,
callback_ctx->updates[n]);
if (ret) {
/* Ignore the error. */
DBG_WARNING("Failed to update keys for Group "