diff options
author | Stefan Metzmacher <metze@samba.org> | 2011-09-13 13:10:33 +0200 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2011-09-13 13:16:09 +0200 |
commit | a4548efe675881ce745368f1e8dc7649a2bba8e2 (patch) | |
tree | 91a05e5b52a2b6395a6a20851fa34c31a69564e3 | |
parent | 96fc0d601899b7c1647cc771f14fcef0b480b26a (diff) | |
download | samba-a4548efe675881ce745368f1e8dc7649a2bba8e2.tar.gz samba-a4548efe675881ce745368f1e8dc7649a2bba8e2.tar.bz2 samba-a4548efe675881ce745368f1e8dc7649a2bba8e2.zip |
s3:libsmb: make use of cli_state_available_size() in cli_smbwrite()
metze
-rw-r--r-- | source3/libsmb/clireadwrite.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source3/libsmb/clireadwrite.c b/source3/libsmb/clireadwrite.c index c714d3b273..a6f79fb1d2 100644 --- a/source3/libsmb/clireadwrite.c +++ b/source3/libsmb/clireadwrite.c @@ -732,7 +732,8 @@ NTSTATUS cli_smbwrite(struct cli_state *cli, uint16_t fnum, char *buf, bytes[0] = 1; do { - size_t size = MIN(size1, cli->max_xmit - 48); + uint32_t usable_space = cli_state_available_size(cli, 48); + size_t size = MIN(size1, usable_space); struct tevent_req *req; uint16_t vwv[5]; uint16_t *ret_vwv; |