summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>2010-03-13 19:30:43 +0100
committerMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>2010-03-14 18:46:21 +0100
commit9b3c45754e9f610a095e6e1b191bb33235e8c314 (patch)
treea9fc2a4dca80d0372c736d23f30384918296bbee /source4
parentcd3c870333d49460c9598a9928622454cd2cefc5 (diff)
downloadsamba-9b3c45754e9f610a095e6e1b191bb33235e8c314.tar.gz
samba-9b3c45754e9f610a095e6e1b191bb33235e8c314.tar.bz2
samba-9b3c45754e9f610a095e6e1b191bb33235e8c314.zip
s4:registry - ldb.c - remove superfluous "query" variable
Diffstat (limited to 'source4')
-rw-r--r--source4/lib/registry/ldb.c6
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",