From: Douglas Bagnall Date: Wed, 8 May 2019 00:50:30 +0000 (+1200) Subject: ldb_map: check a return value (CID 241354) X-Git-Tag: tdb-1.4.1~121 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3de7f430db6237487ac68922c80f6114dcb5434b;p=thirdparty%2Fsamba.git ldb_map: check a return value (CID 241354) Signed-off-by: Douglas Bagnall Reviewed-by: Gary Lockyer --- diff --git a/lib/ldb/ldb_map/ldb_map_outbound.c b/lib/ldb/ldb_map/ldb_map_outbound.c index 1f1a7e80142..c823ba4a5c6 100644 --- a/lib/ldb/ldb_map/ldb_map_outbound.c +++ b/lib/ldb/ldb_map/ldb_map_outbound.c @@ -921,6 +921,9 @@ static int map_subtree_collect_remote(struct ldb_module *module, void *mem_ctx, } map = map_attr_find_local(data, tree->u.equality.attr); + if (map == NULL) { + return LDB_ERR_OPERATIONS_ERROR; + } if (map->convert_operator) { return map->convert_operator(module, mem_ctx, new, tree); }