]> asedeno.scripts.mit.edu Git - linux.git/commit
perf tools: Add pattern name checking to rm_rf
authorJiri Olsa <jolsa@kernel.org>
Sun, 24 Feb 2019 19:06:38 +0000 (20:06 +0100)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 25 Feb 2019 13:33:04 +0000 (10:33 -0300)
commitcdb6b0235f170a5ffcd74731178efc064bd4d24a
treef1b0e474cdc9b0746254813b849d4e9c7940a6ff
parent05a486593977bfcf71de6bf5cad6d045c18829c6
perf tools: Add pattern name checking to rm_rf

Add pattern argument to rm_rf_depth() (and rename it to rm_rf_depth_pat())
to specify the name pattern files need to match inside the directory.

The function fails if we find different file to remove.

Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Alexey Budankov <alexey.budankov@linux.intel.com>
Cc: Andi Kleen <ak@linux.intel.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/20190224190656.30163-3-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/util.c