mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
s4-dreplsrv: fix 'dn' for partition object being created
This commit is contained in:
parent
750300aedf
commit
d08439d42b
@ -52,8 +52,16 @@ WERROR drepl_create_role_owner_source_dsa(struct dreplsrv_service *service,
|
||||
return WERR_NOMEM;
|
||||
}
|
||||
|
||||
sdsa->partition->dn = ldb_get_default_basedn(ldb);
|
||||
sdsa->partition->dn = ldb_dn_copy(sdsa->partition, role_owner_dn);
|
||||
if (!sdsa->partition->dn) {
|
||||
talloc_free(sdsa);
|
||||
return WERR_NOMEM;
|
||||
}
|
||||
sdsa->partition->nc.dn = ldb_dn_alloc_linearized(sdsa->partition, role_owner_dn);
|
||||
if (!sdsa->partition->nc.dn) {
|
||||
talloc_free(sdsa);
|
||||
return WERR_NOMEM;
|
||||
}
|
||||
ret = dsdb_find_guid_by_dn(ldb, role_owner_dn, &sdsa->partition->nc.guid);
|
||||
if (ret != LDB_SUCCESS) {
|
||||
DEBUG(0,(__location__ ": Failed to find GUID for %s\n",
|
||||
|
Loading…
Reference in New Issue
Block a user