Author pitrou
Recipients asvetlov, gvanrossum, pitrou, yselivanov
Date 2017-12-08.10:51:32
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1512730292.3.0.213398074469.issue32251@psf.upfronthosting.co.za>
In-reply-to
Content
I have another question: what happens if there is a partial read?

For example, let's says I return a 1024-bytes buffer in get_buffer(), but recv_into() receives data in 512 chunks.  Is it:

1. getbuffer() is called, returns 1024 bytes buffer
2. recv_into() receives 512 bytes, writes them in buf[0:512]
3. recv_into() receives another 512 bytes, writes them in buf[512:1024]

or is it:

1. getbuffer() is called, returns 1024 bytes buffer
2. recv_into() receives 512 bytes, writes them in buf[0:512]
3. getbuffer() is called, returns another 1024 bytes buffer
4. recv_into() receives 512 bytes, writes them in newbuf[0:512]
History
Date User Action Args
2017-12-08 10:51:32pitrousetrecipients: + pitrou, gvanrossum, asvetlov, yselivanov
2017-12-08 10:51:32pitrousetmessageid: <1512730292.3.0.213398074469.issue32251@psf.upfronthosting.co.za>
2017-12-08 10:51:32pitroulinkissue32251 messages
2017-12-08 10:51:32pitroucreate