From df2bc010776f94d59adf71a438d194667f13edd2 Mon Sep 17 00:00:00 2001 From: Christoph Hellwig Date: Wed, 11 May 2011 15:04:09 +0000 Subject: [PATCH] --- yaml --- r: 251773 b: refs/heads/master c: f1c63b73cf60dc4800cde5ce7fd9466c419e5e36 h: refs/heads/master i: 251771: 5993430d5f4bbb026bbfeed2e13d4737baa98ab4 v: v3 --- [refs] | 2 +- trunk/fs/xfs/xfs_bmap.c | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/[refs] b/[refs] index 30cbd3953552..b892e3b7709d 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 00239acf36d3bba8e7c0609e6c473d6e408a2135 +refs/heads/master: f1c63b73cf60dc4800cde5ce7fd9466c419e5e36 diff --git a/trunk/fs/xfs/xfs_bmap.c b/trunk/fs/xfs/xfs_bmap.c index ebcd45203c3d..896e16f08ed9 100644 --- a/trunk/fs/xfs/xfs_bmap.c +++ b/trunk/fs/xfs/xfs_bmap.c @@ -5143,9 +5143,12 @@ xfs_bunmapi( */ ASSERT(bno >= del.br_blockcount); bno -= del.br_blockcount; - if (bno < got.br_startoff) { - if (--lastx >= 0) - xfs_bmbt_get_all(--ep, &got); + if (got.br_startoff > bno) { + if (--lastx >= 0) { + ep = xfs_iext_get_ext(ifp, + lastx); + xfs_bmbt_get_all(ep, &got); + } } continue; } else if (del.br_state == XFS_EXT_UNWRITTEN) {