diff options
author | Volker Lendecke <vl@samba.org> | 2019-09-03 10:35:33 +0200 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2019-09-04 17:03:33 +0000 |
commit | 3a0047eaf18a1dffdedfd6625aeac9f6d7255045 (patch) | |
tree | 836a767a827e12f318d70d01e2722f80ebf6c6dc /source4/dsdb | |
parent | 09946c558fade9ea64f0ef2357bf865c6e1ec441 (diff) | |
download | samba-3a0047eaf18a1dffdedfd6625aeac9f6d7255045.tar.gz |
dsdb: Fix CID 1453464: Error handling issues (CHECKED_RETURN)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Diffstat (limited to 'source4/dsdb')
-rw-r--r-- | source4/dsdb/schema/schema_set.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/source4/dsdb/schema/schema_set.c b/source4/dsdb/schema/schema_set.c index 943d0ef49f5..2ee2596570e 100644 --- a/source4/dsdb/schema/schema_set.c +++ b/source4/dsdb/schema/schema_set.c @@ -904,6 +904,7 @@ int dsdb_schema_fill_extended_dn(struct ldb_context *ldb, struct dsdb_schema *sc const struct ldb_val *rdn; struct ldb_val guid; NTSTATUS status; + int ret; struct ldb_dn *dn = ldb_dn_new(NULL, ldb, cur->defaultObjectCategory); if (!dn) { @@ -925,7 +926,12 @@ int dsdb_schema_fill_extended_dn(struct ldb_context *ldb, struct dsdb_schema *sc talloc_free(dn); return ldb_operr(ldb); } - ldb_dn_set_extended_component(dn, "GUID", &guid); + ret = ldb_dn_set_extended_component(dn, "GUID", &guid); + if (ret != LDB_SUCCESS) { + ret = ldb_error(ldb, ret, "Could not set GUID"); + talloc_free(dn); + return ret; + } cur->defaultObjectCategory = ldb_dn_get_extended_linearized(cur, dn, 1); talloc_free(dn); |