From: Michael Vrable Date: Mon, 22 Mar 2010 23:38:53 +0000 (-0700) Subject: Fix a bug in committing of dirty inodes to stable storage. X-Git-Url: http://git.vrable.net/?a=commitdiff_plain;h=d2e23899649c348326f306b61d12fbd4f6fb0b66;hp=d7d143ef0ccf0f49a8fd23a3c76bc68c0b04e07e;p=bluesky.git Fix a bug in committing of dirty inodes to stable storage. Previously, if an inode changed while it was being committed, we would stall all future commits. Now allow those commits to proceed once the first commit is done. --- diff --git a/bluesky/cache.c b/bluesky/cache.c index 8d2cda1..1f10db0 100644 --- a/bluesky/cache.c +++ b/bluesky/cache.c @@ -28,10 +28,10 @@ static void writeback_complete(gpointer a, gpointer i) g_mutex_lock(inode->lock); inode->change_commit = inode->change_pending; + inode->change_pending = 0; if (inode->change_count == inode->change_commit) { /* If inode is no longer dirty... */ inode->change_time = 0; - inode->change_pending = 0; } g_mutex_unlock(inode->lock);