summaryrefslogtreecommitdiff
path: root/lib/multi.c
Commit message (Collapse)AuthorAgeFilesLines
* fix compiler warning: defined but not usedYang Tse2008-09-131-3/+1
|
* fix compiler warning: external declaration in primary source fileYang Tse2008-09-131-2/+2
|
* Checked in some code improvements and minor fixes that I discovered in theDan Fandrich2008-09-101-1/+1
| | | | FreeBSD ports system.
* Dmitry Kurochkin fixed pipelining over proxy using the multi interfaceDaniel Stenberg2008-09-081-6/+7
|
* remove unnecessary typecasting of malloc()Yang Tse2008-09-061-1/+1
|
* remove unnecessary typecasting of calloc()Yang Tse2008-09-061-3/+3
|
* - Constantine Sapuntzakis fixed a bug when doing proxy CONNECT with the multiDaniel Stenberg2008-08-231-1/+11
| | | | | interface, and the proxy would send Connection: close during the authentication phase. http://curl.haxx.se/bug/view.cgi?id=2069047
* Fixed an uninitialized variable in multi_runsingle() that could cause aDan Fandrich2008-08-081-1/+1
| | | | request to prematurely end.
* - Christopher Palow fixed a curl_multi_socket() issue which previous causedDaniel Stenberg2008-06-191-0/+5
| | | | | | | | libcurl to not tell the app properly when a socket was closed (when the name resolve done by c-ares is done) and then immediately re-created and put to use again (for the actual connection). Since the closure will make the "watch status" get lost in several event-based systems libcurl will need to tell the app about this close/re-create case.
* In checkPendPipeline() we can't be setting the TIMER_CONNECT correctly as thatDaniel Stenberg2008-06-131-1/+1
| | | | | is for the TCP connect. I changed it to TIMER_PRETRANSFER which seems to be what was intended here.
* - Emil Romanus found a problem and helped me repeat it. It occured when usingDaniel Stenberg2008-05-281-19/+58
| | | | | | the curl_multi_socket() API with HTTP pipelining enabled and could lead to the pipeline basically stalling for a very long period of time until it took off again.
* with pipelining disabled, the state should never be set to WAITDO but ratherDaniel Stenberg2008-05-191-29/+50
| | | | | | | | | go straight to DO we had multiple states for which the internal function returned no socket at all to wait for, with the effect that libcurl calls the socket callback (when curl_multi_socket() is used) with REMOVE prematurely (as it would be added again within very shortly)
* - Stefan Krause reported a busy-looping case when using the multi interfaceDaniel Stenberg2008-05-091-0/+6
| | | | | and doing CONNECT to a proxy. The app would then busy-loop until the proxy completed its response.
* Christopher Palow provided the patch (edited by me) that introducesYang Tse2008-05-071-19/+15
| | | | | | the use of microsecond resolution keys for internal splay trees. http://curl.haxx.se/mail/lib-2008-04/0513.html
* - To make it easier for applications that want lots of magic stuff done onDaniel Stenberg2008-04-301-1/+5
| | | | | | | | | redirections and thus cannot use CURLOPT_FOLLOWLOCATION easily, we now introduce the new CURLINFO_REDIRECT_URL option that lets applications extract the URL libcurl would've redirected to if it had been told to. This then enables the application to continue to that URL as it thinks is suitable, without having to re-implement the magic of creating the new URL from the Location: header etc. Test 1029 verifies it.
* - Added curl_easy_getinfo typechecker.Michal Marek2008-03-181-0/+1
| | | | | - Added macros for curl_share_setopt and curl_multi_setopt to check at least the correct number of arguments.
* - We no longer support setting the CURLOPT_URL option from inside a callbackDaniel Stenberg2008-02-201-38/+7
| | | | | | | | | | | such as the CURLOPT_SSL_CTX_FUNCTION one treat that as if it was a Location: following. The patch that introduced this feature was done for 7.11.0, but this code and functionality has been broken since about 7.15.4 (March 2006) with the introduction of non-blocking OpenSSL "connects". It was a hack to begin with and since it doesn't work and hasn't worked correctly for a long time and nobody has even noticed, I consider it a very suitable subject for plain removal. And so it was done.
* added a comment about the ignoring of the Curl_done() return codeDaniel Stenberg2008-02-171-2/+5
|
* - Dmitry Kurochkin cleaned up the pipelining code and removed the need for andDaniel Stenberg2008-02-031-33/+18
| | | | use of the "is_in_pipeline" struct field.
* Dmitry Kurochkin: In "real world" testing I found more bugs inDaniel Stenberg2008-01-271-0/+3
| | | | | pipelining. Broken connection is not restored and we get into infinite loop. It happens because of wrong is_in_pipeline values.
* Dmitry Kurochkin's pipelining close-down segfault fixDaniel Stenberg2008-01-231-2/+7
|
* Dmitry Kurochkin removed the cancelled state for pipelining, as we agreedDaniel Stenberg2008-01-211-38/+11
| | | | | that it is bad anyway. Starting now, removing a handle that is in used in a pipeline will break the pipeline - it'll be set back up again but still...
* Lau Hang Kin found and fixed a problem with the multi interface when doingDaniel Stenberg2008-01-181-0/+1
| | | | | | CONNECT over a proxy. curl_multi_fdset() didn't report back the socket properly during that state, due to a missing case in the switch in the multi_getsock() function.
* Dmitry Kurochkin's additional pipelining bugfixDaniel Stenberg2008-01-161-1/+5
|
* Dmitry Kurochkin worked a lot on improving the HTTP Pipelining support thatDaniel Stenberg2008-01-161-32/+119
| | | | | | | previously had a number of flaws, perhaps most notably when an application fired up N transfers at once as then they wouldn't pipeline at all that nicely as anyone would think... Test case 530 was also updated to take the improved functionality into account.
* Introducing curl_easy_pause() and new magic return codes for both the readDaniel Stenberg2008-01-081-4/+4
| | | | | and the write callbacks that now can make a connection's reading and/or writing get paused.
* struct HandleData is now called struct SingleRequest, and is only for data thatDaniel Stenberg2007-11-241-6/+6
| | | | | | | | | | | is inited at the start of the DO action. I removed the Curl_transfer_keeper struct completely, and I had to move out a few struct members (that had to be set before DO or used after DONE) to the UrlState struct. The SingleRequest struct is accessed with SessionHandle->req. One of the biggest reasons for doing this was the bunch of duplicate struct members in HandleData and Curl_transfer_keeper since it was really messy to keep track of two variables with the same name and basically the same purpose!
* Rearranged code and changed Curl_readwrite_init() and Curl_pre_readwrite() intoDaniel Stenberg2007-11-151-16/+4
| | | | | | do_init() and do_complete() which now are called first and last in the DO function. It simplified the flow in multi.c and the functions got more sensible names!
* removed space after if and while before the parenthesis for better source codeDaniel Stenberg2007-11-051-39/+39
| | | | consistency
* make sure the code deals with failures on the DO_MORE state properlyDaniel Stenberg2007-11-031-25/+30
|
* Enabled a few more gcc warnings with --enable-debug. Renamed a fewDan Fandrich2007-09-271-3/+3
| | | | variables to avoid shadowing global declarations.
* Fixed an invalid returned error code added in my last submission.Dan Fandrich2007-08-311-1/+1
|
* Fixed a few compiler warnings. Try to do a slightly better job ofDan Fandrich2007-08-301-4/+6
| | | | cleaning up after an OOM condition in curl_multi_add_handle
* Fixed some minor mismatched types found by splint.Dan Fandrich2007-08-261-1/+1
|
* Robert Iakobashvili re-arranged the internal hash code to work with a customDaniel Stenberg2007-06-261-1/+26
| | | | | | hash function for different hashes, and also expanded the default size for the socket hash table used in multi handles to greatly enhance speed when very many connections are added and the socket API is used.
* Shmulik Regev fixed a flaw in the multi interface that occurred when doingDaniel Stenberg2007-06-141-2/+9
| | | | HTTP CONNECT over a proxy
* ouch, two conditionals were turned backwards!Daniel Stenberg2007-06-011-2/+2
|
* do the update timer stuff even when CURLM_CALL_MULTI_PERFORM is returnedDaniel Stenberg2007-06-011-6/+6
|
* Added CURLMOPT_MAXCONNECTS which is a curl_multi_setopt() option for settingDaniel Stenberg2007-05-301-5/+18
| | | | the maximum size of the connection cache maximum size of the multi handle.
* James Bursa fixed a bug in the multi handle code that made the connectionDaniel Stenberg2007-05-071-1/+1
| | | | cache grow a bit too much, beyond the normal 4 * easy_handles.
* Fixed an out of memory handling issue with HTTP pipelines.Dan Fandrich2007-05-021-26/+27
|
* - Set the timeout for easy handles to expire really soon after addition orDaniel Stenberg2007-05-021-0/+19
| | | | | | | when CURLM_CALL_MULTI_PERFORM is returned from curl_multi_socket*/perform, to make applications using only curl_multi_socket() to properly function when adding easy handles "on the fly". Bug report and test app provided by Michael Wallner.
* - Robert Iakobashvil added curl_multi_socket_action() to libcurl, which is aDaniel Stenberg2007-04-161-2/+21
| | | | | | | | function that deprecates the curl_multi_socket() function. Using the new function the application tell libcurl what action that was found in the socket that it passes in. This gives a significant performance boost as it allows libcurl to avoid a call to poll()/select() for every call to curl_multi_socket*().
* fix compiler warningYang Tse2007-04-131-1/+1
|
* Ravi Pratap provided fixes for HTTP pipeliningDaniel Stenberg2007-04-101-17/+56
|
* fix out of memory handling issueYang Tse2007-04-071-0/+1
|
* Robert Iakobashvili made curl_multi_remove_handle() a lot faster when manyDaniel Stenberg2007-04-011-7/+8
| | | | | easy handles are added to a multi handle, by avoiding the looping over all the handles to find which one to remove.
* Check for a NULL easy->easy_conn in multi_getsock() since it can in factDaniel Stenberg2007-03-311-1/+8
| | | | | happen when curl_multi_remove_handle() is called. CID 13. coverity.com scan
* - Daniel Johnson fixed multi code to traverse the easy handle list properly.Daniel Stenberg2007-03-251-2/+2
| | | | A left-over bug from the February 21 fix.
* add missing state name for the debug state switch outputDaniel Stenberg2007-03-231-0/+4
|