Skip to content

Commit

Permalink
Merge tag 'trace-v4.4-rc4-3' of git://git.kernel.org/pub/scm/linux/ke…
Browse files Browse the repository at this point in the history
…rnel/git/rostedt/linux-trace

Pull tracing fixes from Steven Rostedt:
 "Two more fixes:

  1. The recordmcount change had an output that used sprintf()
     (incorrectly) when it should have been a fprintf() to stderr.

  2. The printk_formats file could crash if someone added a
     trace_printk() in the core kernel, and also added one in a module.
     This does not affect production kernels.  Only kernels where
     developers add trace_printk() for debugging can crash"

* tag 'trace-v4.4-rc4-3' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace:
  tracing: Fix setting of start_index in find_next()
  ftrace/scripts: Fix incorrect use of sprintf in recordmcount
  • Loading branch information
torvalds committed Jan 5, 2016
2 parents 3331f99 + f36d1be commit ee9a7d2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions kernel/trace/trace_printk.c
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,7 @@ static const char **find_next(void *v, loff_t *pos)
if (*pos < last_index + start_index)
return __start___tracepoint_str + (*pos - last_index);

start_index += last_index;
return find_next_mod_format(start_index, v, fmt, pos);
}

Expand Down
2 changes: 1 addition & 1 deletion scripts/recordmcount.c
Original file line number Diff line number Diff line change
Expand Up @@ -586,7 +586,7 @@ main(int argc, char *argv[])
do_file(file);
break;
case SJ_FAIL: /* error in do_file or below */
sprintf("%s: failed\n", file);
fprintf(stderr, "%s: failed\n", file);
++n_error;
break;
case SJ_SUCCEED: /* premature success */
Expand Down

0 comments on commit ee9a7d2

Please sign in to comment.