summaryrefslogtreecommitdiff
path: root/source4/lib/ldb/common
diff options
context:
space:
mode:
authorSimo Sorce <idra@samba.org>2008-10-29 08:34:05 -0400
committerSimo Sorce <idra@samba.org>2008-10-29 18:07:29 -0400
commit753af36a3e194f645ec0b68a033199035e71c909 (patch)
treec2fdc4f8d66a3123ac1282b640baa659c975c6f4 /source4/lib/ldb/common
parent7c5f369fafee42b555c3e2b3e3482689b508fe4a (diff)
downloadsamba-753af36a3e194f645ec0b68a033199035e71c909.tar.gz
samba-753af36a3e194f645ec0b68a033199035e71c909.tar.bz2
samba-753af36a3e194f645ec0b68a033199035e71c909.zip
Length comparison of the linearized version is not correct.
The linearized version is not casefolded so length might not match and yet the strings be equivalent. This can happen if one component is case-insensitive and a letter that have an uppercase version of a multibyte character that differ in legth from the corresponding lowercase one.
Diffstat (limited to 'source4/lib/ldb/common')
-rw-r--r--source4/lib/ldb/common/ldb_dn.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/source4/lib/ldb/common/ldb_dn.c b/source4/lib/ldb/common/ldb_dn.c
index e36aea4e69..5e6fb96457 100644
--- a/source4/lib/ldb/common/ldb_dn.c
+++ b/source4/lib/ldb/common/ldb_dn.c
@@ -749,9 +749,6 @@ int ldb_dn_compare_base(struct ldb_dn *base, struct ldb_dn *dn)
if (base->linearized && dn->linearized) {
/* try with a normal compare first, if we are lucky
* we will avoid exploding and casfolding */
- int dif;
- dif = strlen(dn->linearized) - strlen(base->linearized);
- if (dif < 0) return dif;
if (strcmp(base->linearized, &dn->linearized[dif]) == 0) return 0;
}