summaryrefslogtreecommitdiffstats
path: root/source3/passdb/smbpass.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/passdb/smbpass.c')
-rw-r--r--source3/passdb/smbpass.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source3/passdb/smbpass.c b/source3/passdb/smbpass.c
index d2a69ee9a6..0347df4ee9 100644
--- a/source3/passdb/smbpass.c
+++ b/source3/passdb/smbpass.c
@@ -684,7 +684,11 @@ static BOOL mod_smbfilepwd_entry(struct smb_passwd* pwd, BOOL override)
}
}
- if (!found_entry) return False;
+ if (!found_entry) {
+ pw_file_unlock(lockfd, &pw_file_lock_depth);
+ fclose(fp);
+ return False;
+ }
DEBUG(6, ("mod_smbfilepwd_entry: entry exists\n"));