lkml.org 
[lkml]   [2015]   [Aug]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH V7 6/8] perf,tools: Dump per-sample freq/CPU%/CORE_BUSY% in report -D
Em Mon, Aug 31, 2015 at 01:19:40PM +0200, Jiri Olsa escreveu:
> On Fri, Aug 28, 2015 at 05:48:07AM -0400, Kan Liang wrote:
>
> SNIP
>
> >
> > static struct machine *machines__find_for_cpumode(struct machines *machines,
> > @@ -1079,11 +1101,12 @@ static int machines__deliver_event(struct machines *machines,
> >
> > switch (event->header.type) {
> > case PERF_RECORD_SAMPLE:
> > - dump_sample(evsel, event, sample);
> > if (evsel == NULL) {
> > ++evlist->stats.nr_unknown_id;
> > return 0;
> > }
> > + dump_sample(evsel, event, sample);
> > +
>
> could you submit this hunk separately.. seems like we could
> segfault in dump_sample if there's evsel == NULL, right?

Right, this one should be submitted separately, if there is a test right
after we use a pointer, I wouldn't even think about reading
dump_sample() code :-)

- Arnaldo


\
 
 \ /
  Last update: 2015-08-31 23:01    [W:0.600 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site