1
0
mirror of https://github.com/samba-team/samba.git synced 2025-03-08 04:58:40 +03:00

Reset error strings

Avoid leaking error strings up to the application, when we are ignoring them.
(This used to be commit 57b4b43b6548d1cd81cfaebc5ea8abc88aaca989)
This commit is contained in:
Andrew Bartlett 2008-02-08 17:09:49 +11:00
parent 9e681efdf0
commit 5153c67267

View File

@ -59,6 +59,7 @@ static int schema_fsmo_init(struct ldb_module *module)
schema_dn = samdb_schema_dn(module->ldb);
if (!schema_dn) {
ldb_reset_err_string(module->ldb);
ldb_debug(module->ldb, LDB_DEBUG_WARNING,
"schema_fsmo_init: no schema dn present: (skip schema loading)\n");
return ldb_next_init(module);
@ -91,6 +92,7 @@ static int schema_fsmo_init(struct ldb_module *module)
NULL, schema_attrs,
&schema_res);
if (ret == LDB_ERR_NO_SUCH_OBJECT) {
ldb_reset_err_string(module->ldb);
ldb_debug(module->ldb, LDB_DEBUG_WARNING,
"schema_fsmo_init: no schema head present: (skip schema loading)\n");
talloc_free(mem_ctx);