summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2012-04-07 14:17:25 +0200
committerVolker Lendecke <vl@samba.org>2012-04-10 13:20:22 +0200
commit3cca094514fa4488b4ea2a6747b51443ff02a4f0 (patch)
treede17bfd22c6810b4db96a91218b63d0571f13a47 /source3/smbd
parente17d12c23b2f56d8d29f7ee43148be85d28154c6 (diff)
downloadsamba-3cca094514fa4488b4ea2a6747b51443ff02a4f0.tar.gz
samba-3cca094514fa4488b4ea2a6747b51443ff02a4f0.tar.bz2
samba-3cca094514fa4488b4ea2a6747b51443ff02a4f0.zip
s3: Use talloc_get_size instead of strlen
We've just talloc_asprintf'ed the fullpath, so talloc_get_size knows the strlen. Autobuild-User: Volker Lendecke <vl@samba.org> Autobuild-Date: Tue Apr 10 13:20:22 CEST 2012 on sn-devel-104
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/files.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/smbd/files.c b/source3/smbd/files.c
index e01a92e333..c71e864648 100644
--- a/source3/smbd/files.c
+++ b/source3/smbd/files.c
@@ -612,7 +612,7 @@ NTSTATUS file_name_hash(connection_struct *conn,
if (!fullpath) {
return NT_STATUS_NO_MEMORY;
}
- *p_name_hash = hash(fullpath, strlen(fullpath) + 1, 0);
+ *p_name_hash = hash(fullpath, talloc_get_size(fullpath), 0);
DEBUG(10,("file_name_hash: %s hash 0x%x\n",
fullpath,