From: tip-bot for Atsushi Tsuji <a-tsuji@bk.jp.nec.com>
To: linux-tip-commits@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, hpa@zytor.com, mingo@redhat.com,
rostedt@goodmis.org, a-tsuji@bk.jp.nec.com, tglx@linutronix.de
Subject: [tip:tracing/core] tracing: Fix minor bugs for __unregister_ftrace_function_probe
Date: Thu, 17 Sep 2009 07:48:36 GMT [thread overview]
Message-ID: <tip-b36461da2a0389149d7f88f3cbc05a30d1db9faa@git.kernel.org> (raw)
In-Reply-To: <4AAF6726.5090905@bk.jp.nec.com>
Commit-ID: b36461da2a0389149d7f88f3cbc05a30d1db9faa
Gitweb: http://git.kernel.org/tip/b36461da2a0389149d7f88f3cbc05a30d1db9faa
Author: Atsushi Tsuji <a-tsuji@bk.jp.nec.com>
AuthorDate: Tue, 15 Sep 2009 19:06:30 +0900
Committer: Steven Rostedt <rostedt@goodmis.org>
CommitDate: Wed, 16 Sep 2009 09:08:54 -0400
tracing: Fix minor bugs for __unregister_ftrace_function_probe
Fix the condition of strcmp for "*".
Also fix NULL pointer dereference when glob is NULL.
Signed-off-by: Atsushi Tsuji <a-tsuji@bk.jp.nec.com>
LKML-Reference: <4AAF6726.5090905@bk.jp.nec.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
kernel/trace/ftrace.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index 8b23d56..f7ab7fc 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -2062,9 +2062,9 @@ __unregister_ftrace_function_probe(char *glob, struct ftrace_probe_ops *ops,
int i, len = 0;
char *search;
- if (glob && (strcmp(glob, "*") || !strlen(glob)))
+ if (glob && (strcmp(glob, "*") == 0 || !strlen(glob)))
glob = NULL;
- else {
+ else if (glob) {
int not;
type = ftrace_setup_glob(glob, strlen(glob), &search, ¬);
prev parent reply other threads:[~2009-09-17 7:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-15 10:06 [PATCH 1/2] " Atsushi Tsuji
2009-09-16 13:06 ` Steven Rostedt
2009-09-17 7:48 ` tip-bot for Atsushi Tsuji [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=tip-b36461da2a0389149d7f88f3cbc05a30d1db9faa@git.kernel.org \
--to=a-tsuji@bk.jp.nec.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=rostedt@goodmis.org \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome