summaryrefslogtreecommitdiff
path: root/profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs
diff options
context:
space:
mode:
Diffstat (limited to 'profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs')
-rw-r--r--profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs6
1 files changed, 2 insertions, 4 deletions
diff --git a/profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs b/profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs
index 2038a5be..d3baaa36 100644
--- a/profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs
+++ b/profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs
@@ -35,12 +35,10 @@ impl TraceProvider for SimpleperfEtmTraceProvider {
}
fn trace(&self, trace_dir: &Path, tag: &str, sampling_period: &Duration) {
- let mut trace_file = PathBuf::from(trace_dir);
- trace_file.push(trace_provider::construct_file_name(tag));
- trace_file.set_extension(ETM_TRACEFILE_EXTENSION);
+ let trace_file = trace_provider::get_path(trace_dir, tag, ETM_TRACEFILE_EXTENSION);
simpleperf_profcollect::record(
- &trace_file,
+ &*trace_file,
sampling_period,
simpleperf_profcollect::RecordScope::BOTH,
);