summaryrefslogtreecommitdiff
path: root/source4/lib
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2005-08-20 06:01:49 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:33:36 -0500
commit479be53c0a894df441db9a02d0b75b222b374ae9 (patch)
treea52cdb64da92a15af8888827d578e36d600a9078 /source4/lib
parent55f5453bc81d9a3a4fe67ff0a6ba528d8d0f7984 (diff)
downloadsamba-479be53c0a894df441db9a02d0b75b222b374ae9.tar.gz
samba-479be53c0a894df441db9a02d0b75b222b374ae9.tar.bz2
samba-479be53c0a894df441db9a02d0b75b222b374ae9.zip
r9414: Fix failure to find own domain info due to recent ldb_dn upgrade - we
don't use a simple char* here any more. Andrew Bartlett (This used to be commit f21c31c7e151e23caa2699b1727d1ae310fbed4e)
Diffstat (limited to 'source4/lib')
-rw-r--r--source4/lib/credentials.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source4/lib/credentials.c b/source4/lib/credentials.c
index 58a1b8c0e3..aae55be800 100644
--- a/source4/lib/credentials.c
+++ b/source4/lib/credentials.c
@@ -496,7 +496,6 @@ NTSTATUS cli_credentials_set_machine_account(struct cli_credentials *cred)
struct ldb_context *ldb;
int ldb_ret;
struct ldb_message **msgs;
- const char *base_dn = SECRETS_PRIMARY_DOMAIN_DN;
const char *attrs[] = {
"secret",
"samAccountName",
@@ -527,7 +526,8 @@ NTSTATUS cli_credentials_set_machine_account(struct cli_credentials *cred)
/* search for the secret record */
ldb_ret = gendb_search(ldb,
- mem_ctx, base_dn, &msgs, attrs,
+ mem_ctx, ldb_dn_explode(mem_ctx, SECRETS_PRIMARY_DOMAIN_DN),
+ &msgs, attrs,
SECRETS_PRIMARY_DOMAIN_FILTER,
cli_credentials_get_domain(cred));
if (ldb_ret == 0) {