Author: mimir Date: 2004-08-13 22:01:38 +0000 (Fri, 13 Aug 2004) New Revision: 1813 WebSVN: http://websvn.samba.org/websvn/changeset.php?rep=samba&path=/&rev=1813&nolog=1 Log: Forgot to put pdb_context and actually call proper function to add the password to the pdb backend.
rafal Modified: trunk/source/libsmb/trusts_util.c Changeset: Modified: trunk/source/libsmb/trusts_util.c =================================================================== --- trunk/source/libsmb/trusts_util.c 2004-08-13 19:56:19 UTC (rev 1812) +++ trunk/source/libsmb/trusts_util.c 2004-08-13 22:01:38 UTC (rev 1813) @@ -197,9 +197,10 @@ * @return number of passwords migrated */ -int migrate_trust_passwords(void) +int migrate_trust_passwords(struct pdb_context *pdb_ctx) { int migrated = 0; + NTSTATUS nt_status; SAM_TRUST_PASSWD trust; const size_t max_name_len = sizeof(trust.private.uni_name)/2; /* nt workstation trust */ @@ -209,6 +210,9 @@ uint32 chan = 0; DOM_SID dom_sid; + /* sanity-check */ + if (!pdb_ctx) return 0; + /* Checking whether passwords have already been migrated */ if (secrets_passwords_migrated(False)) return migrated; @@ -242,6 +246,7 @@ else return 0; + nt_status = pdb_ctx->pdb_add_trust_passwd(pdb_ctx, &trust); migrated++; }