diff options
author | Matthias Dieter Wallnöfer <mwallnoefer@yahoo.de> | 2010-03-13 19:30:43 +0100 |
---|---|---|
committer | Matthias Dieter Wallnöfer <mwallnoefer@yahoo.de> | 2010-03-14 18:46:21 +0100 |
commit | 9b3c45754e9f610a095e6e1b191bb33235e8c314 (patch) | |
tree | a9fc2a4dca80d0372c736d23f30384918296bbee /source4/lib | |
parent | cd3c870333d49460c9598a9928622454cd2cefc5 (diff) | |
download | samba-9b3c45754e9f610a095e6e1b191bb33235e8c314.tar.gz samba-9b3c45754e9f610a095e6e1b191bb33235e8c314.tar.bz2 samba-9b3c45754e9f610a095e6e1b191bb33235e8c314.zip |
s4:registry - ldb.c - remove superfluous "query" variable
Diffstat (limited to 'source4/lib')
-rw-r--r-- | source4/lib/registry/ldb.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/source4/lib/registry/ldb.c b/source4/lib/registry/ldb.c index 0fab8472a9..9a26887b4b 100644 --- a/source4/lib/registry/ldb.c +++ b/source4/lib/registry/ldb.c @@ -411,7 +411,6 @@ static WERROR ldb_get_value(TALLOC_CTX *mem_ctx, struct hive_key *k, struct ldb_context *c = kd->ldb; struct ldb_result *res; int ret; - char *query; if (name == NULL) { return WERR_INVALID_PARAM; @@ -422,9 +421,8 @@ static WERROR ldb_get_value(TALLOC_CTX *mem_ctx, struct hive_key *k, return ldb_get_default_value(mem_ctx, k, NULL, data_type, data); } else { /* normal value */ - query = talloc_asprintf(mem_ctx, "(value=%s)", name); - ret = ldb_search(c, mem_ctx, &res, kd->dn, LDB_SCOPE_ONELEVEL, NULL, "%s", query); - talloc_free(query); + ret = ldb_search(c, mem_ctx, &res, kd->dn, LDB_SCOPE_ONELEVEL, + NULL, "(value=%s)", name); if (ret != LDB_SUCCESS) { DEBUG(0, ("Error getting values for '%s': %s\n", |