From: Andrew Bartlett Date: Mon, 28 May 2018 01:02:16 +0000 (+1200) Subject: ldb: Indicate that the ltdb_dn_list_sort() in list_union is a bit subtle. X-Git-Tag: ldb-1.4.0~5 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3632775d7ad31e06437ed76b8731d9895930caa1;p=thirdparty%2Fsamba.git ldb: Indicate that the ltdb_dn_list_sort() in list_union is a bit subtle. Signed-off-by: Andrew Bartlett Reviewed-by: Stefan Metzmacher Reviewed-by: Garming Sam --- diff --git a/lib/ldb/ldb_tdb/ldb_index.c b/lib/ldb/ldb_tdb/ldb_index.c index dbe59837f6e..1a5867b7a0d 100644 --- a/lib/ldb/ldb_tdb/ldb_index.c +++ b/lib/ldb/ldb_tdb/ldb_index.c @@ -1310,6 +1310,9 @@ static bool list_union(struct ldb_context *ldb, /* * Sort the lists (if not in GUID DN mode) so we can do * the de-duplication during the merge + * + * NOTE: This can sort the in-memory index values, as list or + * list2 might not be a copy! */ ltdb_dn_list_sort(ltdb, list); ltdb_dn_list_sort(ltdb, list2);