From 1222a1c456785f2b0046efc271ac8bfff3be2753 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 23 Apr 2007 07:23:45 +0000 Subject: r22475: Rather than segfault, show the name of the malformed entry. Andrew Bartlett (This used to be commit e1536014a05645fd2300de5152e966aa1e067436) --- source4/lib/ldb/tools/ad2oLschema.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'source4') diff --git a/source4/lib/ldb/tools/ad2oLschema.c b/source4/lib/ldb/tools/ad2oLschema.c index 04b9efae8f..285820b512 100644 --- a/source4/lib/ldb/tools/ad2oLschema.c +++ b/source4/lib/ldb/tools/ad2oLschema.c @@ -325,6 +325,12 @@ static struct schema_conv process_convert(struct ldb_context *ldb, enum convert_ char *schema_entry = NULL; int j; + if (!name) { + printf("Failed to find lDAPDisplayName for schema DN: %s\n", ldb_dn_get_linearized(msg->dn)); + ret.failures = 1; + continue; + } + /* We have been asked to skip some attributes/objectClasses */ if (attrs_skip && str_list_check_ci(attrs_skip, name)) { ret.skipped++; -- cgit