]> git.baikalelectronics.ru Git - kernel.git/commit
perf tools: Do proper comm override error handling
authorFrederic Weisbecker <fweisbec@gmail.com>
Tue, 14 Jan 2014 15:37:14 +0000 (16:37 +0100)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 16 Jan 2014 19:44:39 +0000 (16:44 -0300)
commite47f11b6152269bc8a05240f1069ffaedb8c49a5
tree26a1d69797a907bedb10bac2a8f84f67e901af0f
parent25c67554b242d673f6ecb7679d1d2bb0c1e99347
perf tools: Do proper comm override error handling

The comm overriding API ignores memory allocation failures by silently
keeping the previous and out of date comm.

As a result, the user may get buggy events without ever being notified
about the problem and its source.

Lets start to fix this by propagating the error from the API. Not all
callers may be doing proper error handling on comm set yet but this is
the first step toward it.

Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/r/1389713836-13375-2-git-send-email-fweisbec@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/comm.c
tools/perf/util/comm.h
tools/perf/util/thread.c