diff options
author | Steven Rostedt (VMware) <rostedt@goodmis.org> | 2019-01-14 22:37:53 +0100 |
---|---|---|
committer | Steven Rostedt (VMware) <rostedt@goodmis.org> | 2019-02-06 17:56:19 +0100 |
commit | 6c6dbce196c201810348b6cef6fc5ec77d4d0973 (patch) | |
tree | bf1ca8349ccf8ef5331aa9cf8f0a24a8bc3fc98b /kernel/trace | |
parent | tracing: Annotate implicit fall through in predicate_parse() (diff) | |
download | linux-6c6dbce196c201810348b6cef6fc5ec77d4d0973.tar.xz linux-6c6dbce196c201810348b6cef6fc5ec77d4d0973.zip |
tracing: Add comment to predicate_parse() about "&&" or "||"
As the predicat_parse() code is rather complex, commenting subtleties is
important. The switch case statement should be commented to describe that it
is only looking for two '&' or '|' together, which is why the fall through
to an error is after the check.
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace')
-rw-r--r-- | kernel/trace/trace_events_filter.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/trace/trace_events_filter.c b/kernel/trace/trace_events_filter.c index eb694756c4bb..f052ecb085e9 100644 --- a/kernel/trace/trace_events_filter.c +++ b/kernel/trace/trace_events_filter.c @@ -491,6 +491,7 @@ predicate_parse(const char *str, int nr_parens, int nr_preds, break; case '&': case '|': + /* accepting only "&&" or "||" */ if (next[1] == next[0]) { ptr++; break; |