adapt to the new protos

This commit is contained in:
Daniel Stenberg 2006-07-30 22:47:53 +00:00
parent 01b2cf82ec
commit 5a1c64d316
1 changed files with 5 additions and 3 deletions

View File

@ -374,6 +374,7 @@ int main(int argc, char **argv)
int selectmaxamount; int selectmaxamount;
struct fdinfo *fdp; struct fdinfo *fdp;
char act; char act;
int running_handles;
memset(&info, 0, sizeof(struct globalinfo)); memset(&info, 0, sizeof(struct globalinfo));
@ -451,7 +452,8 @@ int main(int argc, char **argv)
curl_multi_setopt(multi_handle, CURLMOPT_SOCKETDATA, NULL); curl_multi_setopt(multi_handle, CURLMOPT_SOCKETDATA, NULL);
/* we start the action by calling *socket() right away */ /* we start the action by calling *socket() right away */
while(CURLM_CALL_MULTI_PERFORM == curl_multi_socket_all(multi_handle)); while(CURLM_CALL_MULTI_PERFORM == curl_multi_socket_all(multi_handle,
&running_handles));
printf("Starting timer, expects to run for %ldus\n", RUN_FOR_THIS_LONG); printf("Starting timer, expects to run for %ldus\n", RUN_FOR_THIS_LONG);
timer_start(); timer_start();
@ -486,7 +488,7 @@ int main(int argc, char **argv)
break; break;
case 0: case 0:
timeouts++; timeouts++;
curl_multi_socket(multi_handle, CURL_SOCKET_TIMEOUT); curl_multi_socket(multi_handle, CURL_SOCKET_TIMEOUT, &running_handles);
break; break;
default: default:
@ -510,7 +512,7 @@ int main(int argc, char **argv)
timer_continue(); timer_continue();
if(act & CURL_POLL_OUT) if(act & CURL_POLL_OUT)
act--; act--;
curl_multi_socket(multi_handle, fdp->sockfd); curl_multi_socket(multi_handle, fdp->sockfd, &running_handles);
timer_pause(); timer_pause();
} }
} }