Skip to content

Commit eb4f73b

Browse files
josephhztorvalds
authored andcommitted
ocfs2: remove bogus check in dlm_process_recovery_data
In dlm_process_recovery_data, only when dlm_new_lock failed the ret will be set to -ENOMEM. And in this case, newlock is definitely NULL. So test newlock is meaningless, remove it. Signed-off-by: Joseph Qi <[email protected]> Reviewed-by: Alex Chen <[email protected]> Reviewed-by: Mark Fasheh <[email protected]> Cc: Joel Becker <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent bdec419 commit eb4f73b

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

fs/ocfs2/dlm/dlmrecovery.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2023,11 +2023,8 @@ static int dlm_process_recovery_data(struct dlm_ctxt *dlm,
20232023
dlm_lockres_drop_inflight_ref(dlm, res);
20242024
spin_unlock(&res->spinlock);
20252025

2026-
if (ret < 0) {
2026+
if (ret < 0)
20272027
mlog_errno(ret);
2028-
if (newlock)
2029-
dlm_lock_put(newlock);
2030-
}
20312028

20322029
return ret;
20332030
}

0 commit comments

Comments
 (0)