Bug 9341 - smb2_read: regression in sendfile support check
smb2_read: regression in sendfile support check
Status: RESOLVED FIXED
Product: Samba 4.0
Classification: Unclassified
Component: File services
4.0.0rc3
All All
: P5 normal
: ---
Assigned To: Karolin Seeger
Samba QA Contact
:
Depends on:
Blocks: 8622
  Show dependency treegraph
 
Reported: 2012-10-30 10:13 UTC by Stefan Metzmacher
Modified: 2012-11-05 09:56 UTC (History)
4 users (show)

See Also:


Attachments
Patch from master (applies cleanly to v4-0-test) (1.27 KB, patch)
2012-11-01 13:11 UTC, Michael Adam
metze: review+
vl: review+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Metzmacher 2012-10-30 10:13:58 UTC
Currently we check for this:

if smb2req->in.vector_count < (2*SMBD_SMB2_NUM_IOV_PER_REQ)
    /* no sendfile */

Which is wrong, it should be

if smb2req->in.vector_count >= (2*SMBD_SMB2_NUM_IOV_PER_REQ)
    /* no sendfile */

Which means we don't use sendfile for compound requests.
Comment 1 Michael Adam 2012-11-01 13:11:43 UTC
Created attachment 8125 [details]
Patch from master (applies cleanly to v4-0-test)

This patch is from master.
It was done my metze, tested by the reporter (Sebastien LAVEZE) and reviewed by me.
Comment 2 Stefan Metzmacher 2012-11-01 13:25:47 UTC
Comment on attachment 8125 [details]
Patch from master (applies cleanly to v4-0-test)

looks good
Comment 3 Stefan Metzmacher 2012-11-01 13:26:41 UTC
Karolin, please pick this
Comment 4 Karolin Seeger 2012-11-02 07:42:59 UTC
Pushed to autobuild-v4-0-test.
Comment 5 Karolin Seeger 2012-11-05 09:56:54 UTC
Pushed to v4-0-test.
Closing out bug report.

Thanks!