Skip to content
  1. Oct 14, 2014
  2. Oct 04, 2014
  3. Aug 31, 2014
    • Daniel Stenberg's avatar
      low-speed-limit: avoid timeout flood · cacdc27f
      Daniel Stenberg authored
      Introducing Curl_expire_latest(). To be used when we the code flow only
      wants to get called at a later time that is "no later than X" so that
      something can be checked (and another timeout be added).
      
      The low-speed logic for example could easily be made to set very many
      expire timeouts if it would be called faster or sooner than what it had
      set its own timer and this goes for a few other timers too that aren't
      explictiy checked for timer expiration in the code.
      
      If there's no condition the code that says if(time-passed >= TIME), then
      Curl_expire_latest() is preferred to Curl_expire().
      
      If there exists such a condition, it is on the other hand important that
      Curl_expire() is used and not the other.
      
      Bug: http://curl.haxx.se/mail/lib-2014-06/0235.html
      Reported-by: Florian Weimer
      cacdc27f
  4. Aug 20, 2014
  5. Jul 04, 2014
  6. May 21, 2014
    • Daniel Stenberg's avatar
      bits.close: introduce connection close tracking · df13f8e8
      Daniel Stenberg authored
      Make all code use connclose() and connkeep() when changing the "close
      state" for a connection. These two macros take a string argument with an
      explanation, and debug builds of curl will include that in the debug
      output. Helps tracking connection re-use/close issues.
      df13f8e8
  7. May 15, 2014
    • Daniel Stenberg's avatar
      timers: fix timer regression involving redirects / reconnects · 84bd19ff
      Daniel Stenberg authored
      In commit 0b3750b5 (released in 7.36.0) we fixed a timeout issue
      but instead broke the timings.
      
      To fix this, I introduce a new timestamp to use for the timeouts and
      restored the previous timestamp and timestamp position so that the old
      timer functionality is restored.
      
      In addition to that, that change also broke connection timeouts for when
      more than one connect was used (as it would then count the total time
      from the first connect and not for the most recent one). Now
      Curl_timeleft() has been modified so that it checks against different
      start times depending on which timeout it checks.
      
      Test 1303 is updated accordingly.
      
      Bug: http://curl.haxx.se/mail/lib-2014-05/0147.html
      Reported-by: Ryan Braud
      84bd19ff
  8. Apr 18, 2014
  9. Mar 19, 2014
  10. Jan 18, 2014
  11. Jan 17, 2014
  12. Jan 15, 2014
  13. Jan 11, 2014
    • Daniel Stenberg's avatar
      multi: remove MULTI_TIMEOUT_INACCURACY · 3b183df9
      Daniel Stenberg authored
      With the recently added timeout "reminder" functionality, there's no
      reason left for us to execute timeout code before the time is
      ripe. Simplifies the handling too.
      
      This will make the *TIMEOUT and *CONNECTTIMEOUT options more accurate
      again, which probably is most important when the *_MS versions are used.
      
      In multi_socket, make sure to update 'now' after having handled activity
      on a socket.
      3b183df9
  14. Jan 08, 2014
  15. Dec 28, 2013
  16. Dec 20, 2013
  17. Dec 04, 2013
  18. Nov 27, 2013
  19. Nov 17, 2013
  20. Nov 14, 2013
  21. Nov 10, 2013
  22. Nov 04, 2013
    • Björn Stenberg's avatar
      connect: Add connection delay to Happy Eyeballs. · 02fbc26d
      Björn Stenberg authored
      This patch adds a 200ms delay between the first and second address
      family socket connection attempts.
      
      It also iterates over IP addresses in the order returned by the
      system, meaning most dual-stack systems will try IPv6 first.
      
      Additionally, it refactors the connect code, removing most code that
      handled synchronous connects. Since all sockets are now non-blocking,
      the logic can be made simpler.
      02fbc26d
  23. Nov 03, 2013
  24. Oct 29, 2013
  25. Oct 27, 2013
    • Björn Stenberg's avatar
      Typo fix in trynextip(). · 8230af0b
      Björn Stenberg authored
      8230af0b
    • Björn Stenberg's avatar
      Add "Happy Eyeballs" for IPv4/IPv6. · 7d7df831
      Björn Stenberg authored
      This patch invokes two socket connect()s nearly simultaneously, and
      the socket that is first connected "wins" and is subsequently used for
      the connection. The other is terminated.
      
      There is a very slight IPv4 preference, in that if both sockets connect
      simultaneously IPv4 is checked first and thus will win.
      7d7df831
  26. Oct 26, 2013
    • Daniel Stenberg's avatar
      FTP: make the data connection work when going through proxy · d44b0142
      Daniel Stenberg authored
      This is a regression since the switch to always-multi internally
      c4312741.
      
      Test 1316 was modified since we now clearly call the Curl_client_write()
      function when doing the LIST transfer part and then the
      handler->protocol says FTP and ftpc.transfertype is 'A' which implies
      text converting even though that the response is initially a HTTP
      CONNECT response in this case.
      d44b0142
  27. Jul 23, 2013
  28. Jun 20, 2013
    • Daniel Stenberg's avatar
      multi_socket: react on socket close immediately · 88c5c63f
      Daniel Stenberg authored
      As a remedy to the problem when a socket gets closed and a new one is
      opened with the same file descriptor number and as a result
      multi.c:singlesocket() doesn't detect the difference, the new function
      Curl_multi_closed() gets told when a socket is closed so that it can be
      removed from the socket hash. When the old one has been removed, a new
      socket should be detected fine by the singlesocket() on next invoke.
      
      Bug: http://curl.haxx.se/bug/view.cgi?id=1248
      Reported-by: Erik Johansson
      88c5c63f
  29. May 01, 2013
  30. Apr 08, 2013
  31. Apr 06, 2013
    • Kim Vandry's avatar
      connect: treat an interface bindlocal() problem as a non-fatal error · 090b55c1
      Kim Vandry authored
      I am using curl_easy_setopt(CURLOPT_INTERFACE, "if!something") to force
      transfers to use a particular interface but the transfer fails with
      CURLE_INTERFACE_FAILED, "Failed binding local connection end" if the
      interface I specify has no IPv6 address. The cause is as follows:
      
      The remote hostname resolves successfully and has an IPv6 address and an
      IPv4 address.
      
      cURL attempts to connect to the IPv6 address first.
      
      bindlocal (in lib/connect.c) fails because Curl_if2ip cannot find an
      IPv6 address on the interface.
      
      This is a fatal error in singleipconnect()
      
      This change will make cURL try the next IP address in the list.
      
      Also included are two changes related to IPv6 address scope:
      
      - Filter the choice of address in Curl_if2ip to only consider addresses
      with the same scope ID as the connection address (mismatched scope for
      local and remote address does not result in a working connection).
      
      - bindlocal was ignoring the scope ID of addresses returned by
      Curl_if2ip . Now it uses them.
      
      Bug: http://curl.haxx.se/bug/view.cgi?id=1189
      090b55c1
  32. Apr 02, 2013
    • Daniel Stenberg's avatar
      SO_SNDBUF: don't set SNDBUF for win32 versions vista or later · 43e045fc
      Daniel Stenberg authored
      The Microsoft knowledge-base article
      http://support.microsoft.com/kb/823764 describes how to use SNDBUF to
      overcome a performance shortcoming in winsock, but it doesn't apply to
      Windows Vista and later versions. If the described SNDBUF magic is
      applied when running on those more recent Windows versions, it seems to
      instead have the reversed effect in many cases and thus make libcurl
      perform less good on those systems.
      
      This fix thus adds a run-time version-check that does the SNDBUF magic
      conditionally depending if it is deemed necessary or not.
      
      Bug: http://curl.haxx.se/bug/view.cgi?id=1188
      Reported by: Andrew Kurushin
      Tested by: Christian Hägele
      43e045fc