From b9795632aa1e69a27215a1c20e51ca8f999feed5 Mon Sep 17 00:00:00 2001 From: Brian Aker Date: Tue, 14 Oct 2008 22:24:24 -0700 Subject: [PATCH] Saving fix for busy wait --- clients/memslap.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/clients/memslap.c b/clients/memslap.c index 4a4f9a2e..7aa69ead 100644 --- a/clients/memslap.c +++ b/clients/memslap.c @@ -206,14 +206,7 @@ void scheduler(memcached_server_st *servers, conclusions_st *conclusion) */ pthread_mutex_lock(&counter_mutex); while (thread_counter) - { - struct timespec abstime; - - memset(&abstime, 0, sizeof(struct timespec)); - abstime.tv_sec= 10; - - pthread_cond_timedwait(&count_threshhold, &counter_mutex, &abstime); - } + pthread_cond_wait(&count_threshhold, &counter_mutex); pthread_mutex_unlock(&counter_mutex); gettimeofday(&end_time, NULL); -- 2.30.2