mirror of
https://github.com/samba-team/samba.git
synced 2025-03-12 20:58:37 +03:00
ldb backends need to make sure they are not adding duplicate values to multi-valued attributes in ADD and MODIFY operations. Until now they have done this inefficiently using nested loops. Here we add common functions that deal with large numbers of values in O(n log n) time, but continue to use the simple methods for small numbers of values. These functions take a struct ldb_context pointer and an options flag arguments, although the ldb is not used, and only one bit of the options has meaning. This is to allow further patches to switch on schema-aware comparisons. This entails an ABI jump to add the two new functions. Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>