mirror of
https://github.com/samba-team/samba.git
synced 2025-01-14 19:24:43 +03:00
s3:smbd: fix the maxentries calculation depending on the max_send.
Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
parent
734e1b6504
commit
c899d4fd9c
@ -1699,7 +1699,7 @@ void reply_search(struct smb_request *req)
|
||||
} else {
|
||||
unsigned int i;
|
||||
size_t hdr_size = ((uint8_t *)smb_buf(req->outbuf) + 3 - req->outbuf);
|
||||
size_t available_space = BUFFER_SIZE - hdr_size;
|
||||
size_t available_space = sconn->smb1.sessions.max_send - hdr_size;
|
||||
|
||||
maxentries = MIN(maxentries, available_space/DIR_STRUCT_SIZE);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user