r8529: Matching against the wrong union
authorSimo Sorce <idra@samba.org>
Sun, 17 Jul 2005 14:15:45 +0000 (14:15 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:29:35 +0000 (13:29 -0500)
(This used to be commit 24a65b5ba6e31655bdf49be8076d758206694ac3)

source4/lib/ldb/common/ldb_match.c

index f437f31eac2bf12db092228bf88e57a2bad60ea6..3664855dddd1c82587644607b07f0d11af6e03a2 100644 (file)
@@ -2,6 +2,7 @@
    ldb database library
 
    Copyright (C) Andrew Tridgell  2004-2005
+   Copyright (C) Simo Sorce            2005
 
      ** NOTE! The following LGPL license applies to the ldb
      ** library. This does NOT imply that all of Samba is released
@@ -101,11 +102,11 @@ static int ldb_match_present(struct ldb_context *ldb,
                            enum ldb_scope scope)
 {
 
-       if (ldb_attr_cmp(tree->u.simple.attr, "dn") == 0) {
+       if (ldb_attr_cmp(tree->u.present.attr, "dn") == 0) {
                return 1;
        }
 
-       if (ldb_msg_find_element(msg, tree->u.simple.attr)) {
+       if (ldb_msg_find_element(msg, tree->u.present.attr)) {
                return 1;
        }