aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/localalloc.c
diff options
context:
space:
mode:
authorMark Fasheh <mfasheh@suse.com>2008-10-07 17:25:16 -0400
committerMark Fasheh <mfasheh@suse.com>2008-10-13 20:02:44 -0400
commita81cb88b64a479b78c6dd5666678d50171865db8 (patch)
tree9fe0f67e30d7c70d43785827e57736ac01558c24 /fs/ocfs2/localalloc.c
parentfd8351f83d413b41da956109cf429c15881886e2 (diff)
ocfs2: Don't check for NULL before brelse()
This is pointless as brelse() already does the check. Signed-off-by: Mark Fasheh
Diffstat (limited to 'fs/ocfs2/localalloc.c')
-rw-r--r--fs/ocfs2/localalloc.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/fs/ocfs2/localalloc.c b/fs/ocfs2/localalloc.c
index b1c634d676a0..1c4f0645fb37 100644
--- a/fs/ocfs2/localalloc.c
+++ b/fs/ocfs2/localalloc.c
@@ -294,8 +294,7 @@ int ocfs2_load_local_alloc(struct ocfs2_super *osb)
294 294
295bail: 295bail:
296 if (status < 0) 296 if (status < 0)
297 if (alloc_bh) 297 brelse(alloc_bh);
298 brelse(alloc_bh);
299 if (inode) 298 if (inode)
300 iput(inode); 299 iput(inode);
301 300
@@ -411,8 +410,7 @@ out_commit:
411 ocfs2_commit_trans(osb, handle); 410 ocfs2_commit_trans(osb, handle);
412 411
413out_unlock: 412out_unlock:
414 if (main_bm_bh) 413 brelse(main_bm_bh);
415 brelse(main_bm_bh);
416 414
417 ocfs2_inode_unlock(main_bm_inode, 1); 415 ocfs2_inode_unlock(main_bm_inode, 1);
418 416
@@ -488,8 +486,7 @@ bail:
488 *alloc_copy = NULL; 486 *alloc_copy = NULL;
489 } 487 }
490 488
491 if (alloc_bh) 489 brelse(alloc_bh);
492 brelse(alloc_bh);
493 490
494 if (inode) { 491 if (inode) {
495 mutex_unlock(&inode->i_mutex); 492 mutex_unlock(&inode->i_mutex);
@@ -557,8 +554,7 @@ out_unlock:
557out_mutex: 554out_mutex:
558 mutex_unlock(&main_bm_inode->i_mutex); 555 mutex_unlock(&main_bm_inode->i_mutex);
559 556
560 if (main_bm_bh) 557 brelse(main_bm_bh);
561 brelse(main_bm_bh);
562 558
563 iput(main_bm_inode); 559 iput(main_bm_inode);
564 560
@@ -1281,8 +1277,7 @@ bail:
1281 if (handle) 1277 if (handle)
1282 ocfs2_commit_trans(osb, handle); 1278 ocfs2_commit_trans(osb, handle);
1283 1279
1284 if (main_bm_bh) 1280 brelse(main_bm_bh);
1285 brelse(main_bm_bh);
1286 1281
1287 if (main_bm_inode) 1282 if (main_bm_inode)
1288 iput(main_bm_inode); 1283 iput(main_bm_inode);