summaryrefslogtreecommitdiff
path: root/source4/rpc_server/drsuapi/writespn.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/rpc_server/drsuapi/writespn.c')
-rw-r--r--source4/rpc_server/drsuapi/writespn.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/source4/rpc_server/drsuapi/writespn.c b/source4/rpc_server/drsuapi/writespn.c
index 71ff49d509..2e7bd762bf 100644
--- a/source4/rpc_server/drsuapi/writespn.c
+++ b/source4/rpc_server/drsuapi/writespn.c
@@ -47,7 +47,9 @@ WERROR dcesrv_drsuapi_DsWriteAccountSpn(struct dcesrv_call_state *dce_call, TALL
case 1: {
struct drsuapi_DsWriteAccountSpnRequest1 *req;
struct ldb_message *msg;
- int count, i, ret;
+ uint32_t count;
+ unsigned int i;
+ int ret;
unsigned spn_count=0;
req = &r->in.req->req1;
@@ -96,8 +98,9 @@ WERROR dcesrv_drsuapi_DsWriteAccountSpn(struct dcesrv_call_state *dce_call, TALL
}
/* Apply to database */
- ret = dsdb_modify(b_state->sam_ctx, msg, DSDB_MODIFY_PERMISSIVE);
- if (ret != 0) {
+ ret = dsdb_modify(b_state->sam_ctx, msg,
+ DSDB_MODIFY_PERMISSIVE);
+ if (ret != LDB_SUCCESS) {
DEBUG(0,("Failed to modify SPNs on %s: %s\n",
ldb_dn_get_linearized(msg->dn),
ldb_errstring(b_state->sam_ctx)));