Re: [PATCH 27/30] tools lib traceevent: Carve out events formatparsing routine
From: Arnaldo Carvalho de Melo
Date: Tue Sep 25 2012 - 07:12:01 EST
Em Tue, Sep 25, 2012 at 01:15:05PM +0900, Namhyung Kim escreveu:
> On Mon, 24 Sep 2012 12:59:41 -0300, Arnaldo Carvalho de Melo wrote:
> > + if (add_event(pevent, event))
> > + goto event_add_failed;
> It seems we should set the 'ret' to a proper pevent_errno -
> PEVENT_ERRNO__MEM_ALLOC_FAILED.
> > +event_add_failed:
> > + free(event->system);
> > + free(event->name);
> > + free(event);
>
> At this point, the 'event' also has fields and format information and
> they all need to be freed. Looks like calling pevent_free_format()
> would be the right thing IMHO.
Right, care to send a patch?
This patch even exported pevent_free_format, used in the next patch in
this series, should've used it here :-\
- Arnaldo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/