lkml.org 
[lkml]   [2009]   [Jan]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH 3/3] tracing/ftrace: fix a memory leak in stat tracing


    On Tue, 6 Jan 2009, Andrew Morton wrote:

    > On Tue, 06 Jan 2009 17:33:40 -0500
    > Steven Rostedt <rostedt@goodmis.org> wrote:
    >
    > > static int stat_seq_show(struct seq_file *s, void *v)
    > > {
    > > - struct trace_stat_list *l = list_entry(v, struct trace_stat_list, list);
    > > - return current_tracer.stat_show(s, l->stat);
    > > + struct trace_stat_list *entry =
    > > + list_entry(v, struct trace_stat_list, list);
    > > +
    > > + return current_tracer.stat_show(s, entry->stat);
    > > }
    >
    > Rather than jumping through weird 80-column hoops, one can just do:
    >
    > struct trace_stat_list *entry;
    >
    > ...
    >
    > entry = list_entry(v, struct trace_stat_list, list);

    OK, this is Frederics work. I'll submit a separate clean up patch.

    -- Steve



    \
     
     \ /
      Last update: 2009-01-07 03:55    [W:0.018 / U:1.320 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site