summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2004-08-26 21:39:10 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 10:52:30 -0500
commit5ef08833b8aea6fffe19173349c0ac9b50994b5f (patch)
tree25a973021a1a88360feea80edbcd2406da4969fc /source3
parente4c4d91896f08dadf3bc52e067941adb60de0e00 (diff)
downloadsamba-5ef08833b8aea6fffe19173349c0ac9b50994b5f.tar.gz
samba-5ef08833b8aea6fffe19173349c0ac9b50994b5f.tar.bz2
samba-5ef08833b8aea6fffe19173349c0ac9b50994b5f.zip
r2082: lp_path should be lp_pathname.
Paranoia fix on mangle prefix. Jeremy. (This used to be commit cc91bbe20d9cb26e52ad417f279e2d60c85af2dc)
Diffstat (limited to 'source3')
-rw-r--r--source3/smbd/mangle_hash2.c3
-rw-r--r--source3/smbd/password.c2
2 files changed, 3 insertions, 2 deletions
diff --git a/source3/smbd/mangle_hash2.c b/source3/smbd/mangle_hash2.c
index f68873687b..c6ad1215b0 100644
--- a/source3/smbd/mangle_hash2.c
+++ b/source3/smbd/mangle_hash2.c
@@ -119,7 +119,7 @@ static const char *reserved_names[] =
this hash needs to be fast with a low collision rate (what hash doesn't?)
*/
-static u32 mangle_hash(const char *key, unsigned length)
+static u32 mangle_hash(const char *key, unsigned int length)
{
u32 value;
u32 i;
@@ -129,6 +129,7 @@ static u32 mangle_hash(const char *key, unsigned length)
doesn't depend on the case of the long name. Note that this
is the only place where we need to use a multi-byte string
function */
+ length = MIN(length,sizeof(fstring)-1);
strncpy(str, key, length);
str[length] = 0;
strupper_m(str);
diff --git a/source3/smbd/password.c b/source3/smbd/password.c
index decac845ac..cf3c3d64d2 100644
--- a/source3/smbd/password.c
+++ b/source3/smbd/password.c
@@ -272,7 +272,7 @@ int register_vuid(auth_serversupplied_info *server_info, DATA_BLOB session_key,
vuser->user.unix_name, vuser->unix_homedir);
} else {
DEBUG(3, ("Using static (or previously created) service for user '%s'; path = '%s'\n",
- vuser->user.unix_name, lp_path(servicenumber) ));
+ vuser->user.unix_name, lp_pathname(servicenumber) ));
vuser->homes_snum = servicenumber;
}
}