s3:smb2_server: only allocate the required buffer in the smb2 recvfile() code path
authorStefan Metzmacher <metze@samba.org>
Fri, 15 Nov 2013 08:12:40 +0000 (09:12 +0100)
committerJeremy Allison <jra@samba.org>
Fri, 11 Apr 2014 19:41:08 +0000 (21:41 +0200)
commit535103e7a38e175fec082a658c2b70dbdd9af33e
treef46e325ba6ccba10774534e9b22920b19134424b
parent80de72bb57520a1a14c3d3db3f31dc588d0afd64
s3:smb2_server: only allocate the required buffer in the smb2 recvfile() code path

This way the buffer will likely be allocated within the existing talloc_pool,
which avoids one malloc() per request.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/smbd/globals.h
source3/smbd/smb2_server.c