summaryrefslogtreecommitdiff
path: root/tests/libtest/lib503.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2003-10-24 20:58:34 +0000
committerDaniel Stenberg <daniel@haxx.se>2003-10-24 20:58:34 +0000
commitda0b380655ad10865c8e56b15641373b656f0807 (patch)
treebc3b52f01aec133e4c1b7d5efc50d75364bd91bf /tests/libtest/lib503.c
parented7ac3c932b08bb72172623041f7660a601f5f87 (diff)
downloadcurl-da0b380655ad10865c8e56b15641373b656f0807.tar.gz
don't select() forever, set a timeout so at least the test fails nice
Diffstat (limited to 'tests/libtest/lib503.c')
-rw-r--r--tests/libtest/lib503.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/libtest/lib503.c b/tests/libtest/lib503.c
index c77e084bc..126e257a6 100644
--- a/tests/libtest/lib503.c
+++ b/tests/libtest/lib503.c
@@ -40,6 +40,7 @@ CURLcode test(char *URL)
while(!done) {
fd_set rd, wr, exc;
int max_fd;
+ struct timeval interval={1,0};
while (res == CURLM_CALL_MULTI_PERFORM) {
res = curl_multi_perform(m, &running);
@@ -66,7 +67,7 @@ CURLcode test(char *URL)
return 89;
}
- if (select(max_fd+1, &rd, &wr, &exc, NULL) == -1) {
+ if (select(max_fd+1, &rd, &wr, &exc, &interval) == -1) {
fprintf(stderr, "bad select??\n");
return 95;
}