diff options
author | Jeremy Allison <jra@samba.org> | 2010-04-13 18:41:14 -0700 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2010-04-13 18:41:14 -0700 |
commit | f3b8e31f83c44f1e72b15711542d817af7ec9506 (patch) | |
tree | d2747a4497220392a2f12ac47cb4c6640eb2ac68 /source3/libsmb/clireadwrite.c | |
parent | 589a42e2da7d7cd382deb94c57b0c6dbca269e55 (diff) | |
download | samba-f3b8e31f83c44f1e72b15711542d817af7ec9506.tar.gz samba-f3b8e31f83c44f1e72b15711542d817af7ec9506.tar.bz2 samba-f3b8e31f83c44f1e72b15711542d817af7ec9506.zip |
Split out the client unix capabilities to those the server offered, and those the client asked for.
This fixes a bug when using encrypted transport and DFS links. Found
by my basic DFS torture test, which I'll check in next. Testing *rocks* :-).
Jeremy.
Diffstat (limited to 'source3/libsmb/clireadwrite.c')
-rw-r--r-- | source3/libsmb/clireadwrite.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/libsmb/clireadwrite.c b/source3/libsmb/clireadwrite.c index 7b688d4ff3..e9a9e0ed3d 100644 --- a/source3/libsmb/clireadwrite.c +++ b/source3/libsmb/clireadwrite.c @@ -25,7 +25,7 @@ static size_t cli_read_max_bufsize(struct cli_state *cli) { if (!client_is_signing_on(cli) && !cli_encryption_on(cli) - && (cli->posix_capabilities & CIFS_UNIX_LARGE_READ_CAP)) { + && (cli->server_posix_capabilities & CIFS_UNIX_LARGE_READ_CAP)) { return CLI_SAMBA_MAX_POSIX_LARGE_READX_SIZE; } if (cli->capabilities & CAP_LARGE_READX) { @@ -44,7 +44,7 @@ static size_t cli_write_max_bufsize(struct cli_state *cli, uint16_t write_mode) if (write_mode == 0 && !client_is_signing_on(cli) && !cli_encryption_on(cli) && - (cli->posix_capabilities & CIFS_UNIX_LARGE_WRITE_CAP) && + (cli->server_posix_capabilities & CIFS_UNIX_LARGE_WRITE_CAP) && (cli->capabilities & CAP_LARGE_FILES)) { /* Only do massive writes if we can do them direct * with no signing or encrypting - not on a pipe. */ |