summaryrefslogtreecommitdiff
path: root/debian/patches/0007-ext2fs-improve-enable-disable-_caching.patch
blob: fa8931f5cac4274066309b2b2c4e59fd9027e2a6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
From e3b88fd752f6285d7cd07a87891ec83f5152cb5b Mon Sep 17 00:00:00 2001
From: Justus Winter <4winter@informatik.uni-hamburg.de>
Date: Fri, 9 May 2014 10:07:28 +0200
Subject: [PATCH 07/13] ext2fs: improve {enable,disable}_caching

* ext2fs/pager.c (enable_caching, disable_caching): Iterate over the
pager class instead of over both pager buckets.
---
 ext2fs/pager.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/ext2fs/pager.c b/ext2fs/pager.c
index 017efcc..6328f3b 100644
--- a/ext2fs/pager.c
+++ b/ext2fs/pager.c
@@ -1409,8 +1409,7 @@ disable_caching ()
 
   /* Loop through the pagers and turn off caching one by one,
      synchronously.  That should cause termination of each pager. */
-  ports_bucket_iterate (disk_pager_bucket, block_cache);
-  ports_bucket_iterate (file_pager_bucket, block_cache);
+  ports_class_iterate (_pager_class, block_cache);
 }
 
 static void
@@ -1438,8 +1437,7 @@ enable_caching ()
       return 0;
     }
 
-  ports_bucket_iterate (disk_pager_bucket, enable_cache);
-  ports_bucket_iterate (file_pager_bucket, enable_cache);
+  ports_class_iterate (_pager_class, enable_cache);
 }
 
 /* Tell diskfs if there are pagers exported, and if none, then
-- 
2.0.0.rc0