mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-20 22:59:34 -05:00
Update pthread preemptive test. Still needs work.
This commit is contained in:
parent
7e6ad5100c
commit
b8d552b9b3
2 changed files with 219 additions and 213 deletions
13
configure.in
13
configure.in
|
|
@ -501,15 +501,18 @@ if test $ol_with_threads = auto -o $ol_with_threads = posix ; then
|
||||||
int task(arg)
|
int task(arg)
|
||||||
int *arg;
|
int *arg;
|
||||||
{
|
{
|
||||||
|
int i;
|
||||||
struct timeval tv;
|
struct timeval tv;
|
||||||
|
|
||||||
tv.tv_sec=4;
|
tv.tv_sec=5;
|
||||||
tv.tv_usec=0;
|
tv.tv_usec=0;
|
||||||
select(0, NULL, NULL, NULL, &tv);
|
|
||||||
|
|
||||||
tv.tv_sec=6;
|
/* we're not interested in any fds */
|
||||||
tv.tv_usec=0;
|
i = select(FD_SETSIZE, NULL, NULL, NULL, &tv);
|
||||||
select(0, NULL, NULL, NULL, &tv);
|
|
||||||
|
if(i < 0) {
|
||||||
|
perror("select");
|
||||||
|
}
|
||||||
|
|
||||||
exit(1); /* if we exit here, the select blocked the whole process */
|
exit(1); /* if we exit here, the select blocked the whole process */
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue