curl-library
Re: working on a new API
Date: Sat, 27 Oct 2001 09:49:00 -0700
Steve Dekorte wrote:
> /* suggested functions. Daniel's note: I'm not sure they add any real
> * value. Do they? */
> curl_select_readsize(select_handle, int);
> curl_select_writesize(select_handle, int);
Are you using non-blocking IO? If so, you shouldn't try to write more than
about 12KB at a time (at least in Linux)...that seems to be the max
amount it will take in one call to write (to a socket).
> I was thinking it would set the max read & write size per select_perform
> call. This might make more sense as a curl_handle call too. I was
> thinking it would be usefull for large transfers. For example, if you're
> sending a 200M file, you're not going to dump the whole thing into your
> socket buffer in one pass.
If you use NON-Blocking IO it doesn't really matter because you will
never block on the socket. Of course, you have to buffer non-written
bytes in memory so you have to be careful about that...
-- Ben Greear <greearb_at_candelatech.com> <Ben_Greear AT excite.com> President of Candela Technologies Inc http://www.candelatech.com ScryMUD: http://scry.wanfear.com http://scry.wanfear.com/~greearReceived on 2001-10-27