diff options
author | Volker Lendecke <vlendec@samba.org> | 2006-01-28 17:08:24 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 11:06:17 -0500 |
commit | e747ea7250b3ff19aee49072a2cf95840ff50b85 (patch) | |
tree | c22cfb14c913b0c3c9b8a7125d7d87751fb7389d /source/passdb | |
parent | 246b5b43566f15732091ec9a775b864399f9418d (diff) | |
download | samba-e747ea7250b3ff19aee49072a2cf95840ff50b85.tar.gz samba-e747ea7250b3ff19aee49072a2cf95840ff50b85.tar.xz samba-e747ea7250b3ff19aee49072a2cf95840ff50b85.zip |
r13209: Make smbpasswd -a work again if passdb did not exist.
Volker
Diffstat (limited to 'source/passdb')
-rw-r--r-- | source/passdb/pdb_tdb.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/source/passdb/pdb_tdb.c b/source/passdb/pdb_tdb.c index 164ec722998..370c8adc7dc 100644 --- a/source/passdb/pdb_tdb.c +++ b/source/passdb/pdb_tdb.c @@ -423,6 +423,7 @@ static NTSTATUS tdbsam_getsampwnam (struct pdb_methods *my_methods, SAM_ACCOUNT if ((pwd_tdb = tdbsam_tdbopen(tdb_state->tdbsam_location, O_CREAT|O_RDWR )) != NULL) { DEBUG(0, ("pdb_getsampwnam: TDB passwd (%s) did not exist. File successfully created.\n", tdb_state->tdbsam_location)); + tdb_close(pwd_tdb); } else { DEBUG(0, ("pdb_getsampwnam: TDB passwd (%s) does not exist. Couldn't create new one. Error was: %s\n", tdb_state->tdbsam_location, strerror(errno))); |