summaryrefslogtreecommitdiff
path: root/source3/utils
diff options
context:
space:
mode:
authorGerald Carter <jerry@samba.org>2004-02-11 21:10:04 +0000
committerGerald Carter <jerry@samba.org>2004-02-11 21:10:04 +0000
commitda520049883b7f95e468a73ebb2c2511e794f977 (patch)
tree8b3c8ddc8595fb178b186eea828a2e36aecdcf33 /source3/utils
parent987083010441d091d693d6114a7015d5f05d6cd7 (diff)
downloadsamba-da520049883b7f95e468a73ebb2c2511e794f977.tar.gz
samba-da520049883b7f95e468a73ebb2c2511e794f977.tar.bz2
samba-da520049883b7f95e468a73ebb2c2511e794f977.zip
fix set/getsampwent iterator in tdbsam to use an allocated list
(This used to be commit 8734d91cd7681219f1389e3c41979028eadbb7fe)
Diffstat (limited to 'source3/utils')
-rw-r--r--source3/utils/pdbedit.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source3/utils/pdbedit.c b/source3/utils/pdbedit.c
index f402567b74..83663c52b6 100644
--- a/source3/utils/pdbedit.c
+++ b/source3/utils/pdbedit.c
@@ -251,13 +251,15 @@ static int fix_users_list (struct pdb_context *in)
if (!(NT_STATUS_IS_OK(pdb_init_sam(&sam_pwent)))) return 1;
while (check && (ret = NT_STATUS_IS_OK(in->pdb_getsampwent (in, sam_pwent)))) {
+ printf("Updating record for user %s\n", pdb_get_username(sam_pwent));
+
if (!pdb_update_sam_account(sam_pwent)) {
- DEBUG(0, ("Update of user %s failed!\n", pdb_get_username(sam_pwent)));
+ printf("Update of user %s failed!\n", pdb_get_username(sam_pwent));
}
pdb_free_sam(&sam_pwent);
check = NT_STATUS_IS_OK(pdb_init_sam(&sam_pwent));
if (!check) {
- DEBUG(0, ("Failed to initialise new SAM_ACCOUNT structure (out of memory?)\n"));
+ fprintf(stderr, "Failed to initialise new SAM_ACCOUNT structure (out of memory?)\n");
}
}