s3: libsmbclient: Re-resolving targetcli on every read/write/lseek/ftruncate/close...
commit3f61d552a59ca6a15ed7f425b290fff5e24a915b
authorJeremy Allison <jra@samba.org>
Thu, 28 May 2015 18:07:41 +0000 (28 11:07 -0700)
committerKarolin Seeger <kseeger@samba.org>
Mon, 15 Jun 2015 20:52:12 +0000 (15 22:52 +0200)
tree628f05ca3238c676ad3527725d800b4bc9074355
parent97d9d0bbedaec4071c19f613626e38394edb511e
s3: libsmbclient: Re-resolving targetcli on every read/write/lseek/ftruncate/close is both incorrect and slow.

Cache targetcli on file open in the SMBCFILE struct.

Bug 11295 - Excessive cli_resolve_path() usage can slow down transmission.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11295

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 9f57244bbd1ffa203a1f50bb289789628c4a3f66)
source3/include/libsmb_internal.h
source3/libsmb/libsmb_file.c