summaryrefslogtreecommitdiff
path: root/source4/libcli/auth
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2008-12-19 08:18:57 +1100
committerAndrew Bartlett <abartlet@samba.org>2008-12-19 08:18:57 +1100
commitff98d7f9ce1213aeff3d196d8f415303974ffd77 (patch)
treedc9d54a519913705c1c80ead211bf206554dc5b8 /source4/libcli/auth
parent21702bfcdece4e71dcb4ab50e111911a5777f9a5 (diff)
downloadsamba-ff98d7f9ce1213aeff3d196d8f415303974ffd77.tar.gz
samba-ff98d7f9ce1213aeff3d196d8f415303974ffd77.tar.bz2
samba-ff98d7f9ce1213aeff3d196d8f415303974ffd77.zip
Fix failures setting a random password
The test in extract_pw_from_buffer was incorrect: It tested if the first byte of the new password was 0 (a 1/256 chance for the random passwords), not if the password was allocated. Andrew Bartlett
Diffstat (limited to 'source4/libcli/auth')
-rw-r--r--source4/libcli/auth/smbencrypt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source4/libcli/auth/smbencrypt.c b/source4/libcli/auth/smbencrypt.c
index b902dddb0f..bbb363e0dd 100644
--- a/source4/libcli/auth/smbencrypt.c
+++ b/source4/libcli/auth/smbencrypt.c
@@ -585,7 +585,7 @@ bool extract_pw_from_buffer(TALLOC_CTX *mem_ctx,
*new_pass = data_blob_talloc(mem_ctx, &in_buffer[512 - byte_len], byte_len);
- if (!*new_pass->data) {
+ if (!new_pass->data) {
return false;
}