curl-library
Re: Patch: partial fix for bug #948950
Date: Tue, 16 Nov 2004 17:34:54 -0800
On Tue, Nov 16, 2004 at 06:58:54PM -0600, David Phillips wrote:
> Please give me feedback on this patch. It currently serves our needs,
> but I would like to get this fix into the main distribution and
> hopefully into the next release.
This looks like a clever approach to maintaining backward compatibility while
still fixing the problem in the common cases. I have one suggestion: rather
than asserting the fd values, which will terminate the program if it fails,
why not propagate the error to the user as a CURLE_READ_ERROR or a new error
message? That gives the user a chance to retry the operation after freeing
some handles.
Also, this part of the patch looks suspicious:
>
> - if(k->upload_done) {
> + if(k->upload_done)
> /* switch off writing, we're done! */
> k->keepon &= ~KEEP_WRITE; /* we're done writing */
> - FD_ZERO(&k->wkeepfd);
> writedone = TRUE;
> - }
> }
Removing the brackets causes writedone to be set unconditionally.
>>> Dan
-- http://www.MoveAnnouncer.com The web change of address service Let webmasters know that your web site has movedReceived on 2004-11-17