ldb_dn: remove unreachable code in dn_explode
[samba.git] / lib / ldb / common / ldb_dn.c
index 3bd655adbd5154754ab5c1e5cbaa214acb53df7c..f053e815ad49d44f337a916f2095cd5d586e3113 100644 (file)
@@ -359,9 +359,6 @@ static bool ldb_dn_explode(struct ldb_dn *dn)
                                        ex_name = d;
                                        in_ex_name = true;
                                        continue;
-                               } else if (p[0] == '\0') {
-                                       p++;
-                                       continue;
                                } else {
                                        in_extended = false;
                                        in_attr = true;
@@ -474,12 +471,6 @@ static bool ldb_dn_explode(struct ldb_dn *dn)
                                continue;
                        }
 
-                       if (trim && (*p != '=')) {
-                               /* spaces/tabs are not allowed */
-                               ldb_dn_mark_invalid(dn);
-                               goto failed;
-                       }
-
                        if (*p == '=') {
                                /* attribute terminated */
                                in_attr = false;