perf tools: Normalize sq_quote_argv() error reporting
authorArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 14 Oct 2016 20:57:11 +0000 (17:57 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 24 Oct 2016 14:07:44 +0000 (11:07 -0300)
commite7b32d12a287a79f2831c1246baf3de0aed95dcc
treebda9f8eedf847d0579bc2de14e3dd43bd8ddcd2d
parent47b5757bac03c3387ccbe95507917b0f1dd6bb5b
perf tools: Normalize sq_quote_argv() error reporting

It already returns whatever strbuf_(grow|addch)() returns in case of
failure, so just return -ENOSPC in the only case where it was die()ing.
When it returns, its only caller will call die() anyway, so no need to
be so eager, die later.

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/n/tip-as05b7mbogprlwi8iarwns8e@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/quote.c