* [patch] ocfs2: remove unneeded NULL check
@ 2014-11-28 8:30 Dan Carpenter
0 siblings, 0 replies; only message in thread
From: Dan Carpenter @ 2014-11-28 8:30 UTC (permalink / raw)
To: ocfs2-devel
In 1faf289454b9 ('ocfs2_dlm: disallow a domain join if node maps
mismatch') then we introduced a new earlier NULL check so this one is
not needed. Also static checkers complain because we dereference it
first and then check for NULL.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
diff --git a/fs/ocfs2/dlm/dlmdomain.c b/fs/ocfs2/dlm/dlmdomain.c
index 02d315f..50a59d2 100644
--- a/fs/ocfs2/dlm/dlmdomain.c
+++ b/fs/ocfs2/dlm/dlmdomain.c
@@ -877,7 +877,7 @@ static int dlm_query_join_handler(struct o2net_msg *msg, u32 len, void *data,
* to be put in someone's domain map.
* Also, explicitly disallow joining at certain troublesome
* times (ie. during recovery). */
- if (dlm && dlm->dlm_state != DLM_CTXT_LEAVING) {
+ if (dlm->dlm_state != DLM_CTXT_LEAVING) {
int bit = query->node_idx;
spin_lock(&dlm->spinlock);
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2014-11-28 8:30 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-11-28 8:30 [patch] ocfs2: remove unneeded NULL check Dan Carpenter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).