From bb236704d338312192c155f83cd5584d2184d951 Mon Sep 17 00:00:00 2001 From: Tom Maher Date: Tue, 3 Feb 2004 04:53:43 +0000 Subject: [PATCH] acquire-fsync-lock-inside-while-loop-20040202 FIXES 3205 in order to not violate the invariant that pthread_cond_timedwait be called with a locked mutex, we must relock if we unlock. --- src/viced/viced.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/viced/viced.c b/src/viced/viced.c index 5690321..68b76bd 100644 --- a/src/viced/viced.c +++ b/src/viced/viced.c @@ -482,8 +482,8 @@ FsyncCheckLWP() assert(pthread_mutex_init(&fsync_glock_mutex, NULL) == 0); #endif - FSYNC_LOCK; while (1) { + FSYNC_LOCK; #ifdef AFS_PTHREAD_ENV /* rounding is fine */ fsync_next.tv_nsec = 0; -- 1.9.4