title: curl hanging, despite connect-timeout and max-time
body: <p>I have some scripts retrieving resources (image files etc) using system calls to curl. Occasionally, these will fail to finish, and will show as pipe_w in process listings.</p>
  
  <pre><code>F S UID        PID  PPID  C PRI  NI ADDR SZ WCHAN  STIME TTY          TIME CMD
  0 S root      4378  4086  0  82   2 - 16002 pipe_w Jan10 ?        00:00:00 curl -JO --max-time 60 --connect-timeout 60 https://address/path/to/resource?identifier=tag
  </code></pre>
  
  <p>If I understand correctly, I can use connect-timeout to set the # of seconds to try and make the connection, and max-time to limit the amount of time to wait for response from the remote machine.</p>
  
  <pre><code>curl -JO --max-time 60 --connect-timeout 60 https://address/path/to/resource?identifier=tag
  </code></pre>
  
  <p>Any suggestions as to how I can force curl to continue past this? Or pointers on what might cause this?</p>
  
  <p>This is using curl 7.21.0, on a stock ubuntu 10.10.</p>