Re: [PATCH 01/10] perf, tools: Factor out scale conversion code

From: Arnaldo Carvalho de Melo
Date: Fri Oct 14 2016 - 12:39:09 EST


Em Fri, Oct 14, 2016 at 09:36:42AM -0700, Andi Kleen escreveu:
> > I tools/ specifically, I try to use the same constructs, list.h, rbtree,
> > WARN_, pr_, etc, not panic()'ing, etc.
> >
> > In this specific case, doing a:
> >
> > printf("life is hard, I give up"); exit(1);
>
> Ok that would be just what a wrapper does, only open coded.
>
> How about we just add helpers for these cases?
>
> xstrdup
> xmalloc
> xasprintf

Nope, we had those, I removed them already.

- Arnaldo