[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170712073340.4enzeojeoupuds5a@mwanda>
Date: Wed, 12 Jul 2017 10:33:40 +0300
From: Dan Carpenter <dan.carpenter@...cle.com>
To: Steven Rostedt <rostedt@...dmis.org>
Cc: Ingo Molnar <mingo@...hat.com>, linux-kernel@...r.kernel.org,
kernel-janitors@...r.kernel.org
Subject: [PATCH 1/2] ftrace: remove an unneeded NULL check
"func" can't be NULL and it doesn't make sense to check because we've
already derefenced it.
Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index 2953d558bbee..2a3c45743f54 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -3950,7 +3950,7 @@ static int cache_mod(struct trace_array *tr,
continue;
/* no func matches all */
- if (!func || strcmp(func, "*") == 0 ||
+ if (strcmp(func, "*") == 0 ||
(ftrace_mod->func &&
strcmp(ftrace_mod->func, func) == 0)) {
ret = 0;
Powered by blists - more mailing lists