From 2cbc63ca8bbfcb91bce775651e1acc0994a18ac0 Mon Sep 17 00:00:00 2001 From: Raghavendra G Date: Sun, 23 Aug 2009 22:29:19 +0000 Subject: stat/prefetch: free cache if it cannot be put into context of fd Signed-off-by: Anand V. Avati BUG: 221 (stat prefetch implementation) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=221 --- xlators/performance/stat-prefetch/src/stat-prefetch.c | 1 + 1 file changed, 1 insertion(+) (limited to 'xlators') diff --git a/xlators/performance/stat-prefetch/src/stat-prefetch.c b/xlators/performance/stat-prefetch/src/stat-prefetch.c index 663ddc69a10..a35d30e641f 100644 --- a/xlators/performance/stat-prefetch/src/stat-prefetch.c +++ b/xlators/performance/stat-prefetch/src/stat-prefetch.c @@ -525,6 +525,7 @@ sp_readdir_cbk (call_frame_t *frame, void *cookie, xlator_t *this, ret = sp_put_cache (this, fd, cache); if (ret == -1) { + sp_cache_free (cache); goto out; } } -- cgit