From: Dan Carpenter <dan.carpenter@oracle.com>
To: kernel-janitors@vger.kernel.org
Subject: re: tracing: Add help of snapshot feature when snapshot is empty
Date: Fri, 20 Jun 2014 17:40:04 +0000 [thread overview]
Message-ID: <20140620174004.GA10971@mwanda> (raw)
Hello Steven Rostedt (Red Hat),
This is a semi-automatic email about new static checker warnings.
The patch d8741e2e88ac: "tracing: Add help of snapshot feature when
snapshot is empty" from Mar 5, 2013, leads to the following Smatch
complaint:
kernel/trace/trace.c:2933 s_show()
error: we previously assumed 'iter->tr' could be null (see line 2927)
kernel/trace/trace.c
2926 if (iter->ent = NULL) {
2927 if (iter->tr) {
^^^^^^^^
Existing check for "iter->tr".
2928 seq_printf(m, "# tracer: %s\n", iter->trace->name);
2929 seq_puts(m, "#\n");
2930 test_ftrace_alive(m);
2931 }
2932 if (iter->snapshot && trace_empty(iter))
2933 print_snapshot_help(m, iter);
^^^^^^^^^^^^^^^^^^^^^^^^^^^
"iter->tr" gets dereferenced inside the new call to print_snapshot_help().
2934 else if (iter->trace && iter->trace->print_header)
2935 iter->trace->print_header(m);
regards,
dan carpenter
reply other threads:[~2014-06-20 17:40 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20140620174004.GA10971@mwanda \
--to=dan.carpenter@oracle.com \
--cc=kernel-janitors@vger.kernel.org \
/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