summaryrefslogtreecommitdiff
path: root/source4/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source4/lib')
-rw-r--r--source4/lib/ldb/common/ldb_dn.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source4/lib/ldb/common/ldb_dn.c b/source4/lib/ldb/common/ldb_dn.c
index bebb6cc9a0..064dc27a27 100644
--- a/source4/lib/ldb/common/ldb_dn.c
+++ b/source4/lib/ldb/common/ldb_dn.c
@@ -493,11 +493,11 @@ int ldb_dn_compare_base(struct ldb_context *ldb,
if (base == NULL || base->comp_num == 0) return 0;
if (dn == NULL || dn->comp_num == 0) return -1;
+ /* if the base has more componts than the dn, then they differ */
if (base->comp_num > dn->comp_num) {
return (dn->comp_num - base->comp_num);
}
- /* if the number of components doesn't match they differ */
n0 = base->comp_num - 1;
n1 = dn->comp_num - 1;
while (n0 >= 0 && n1 >= 0) {