diff options
author | Chris Wailes <chriswailes@google.com> | 2022-11-16 15:49:28 -0800 |
---|---|---|
committer | Chris Wailes <chriswailes@google.com> | 2022-11-16 15:49:28 -0800 |
commit | 56a7a426188328ff3b27deebaf1c01127f8076af (patch) | |
tree | 04d60ba931c40bddb6ebe852757e6c70b4894b30 /profcollectd | |
parent | 36c12bdf84dd29f474ce9b5afb4166a087e8cdf7 (diff) | |
download | extras-56a7a426188328ff3b27deebaf1c01127f8076af.tar.gz |
Fix warnings from rustc 1.65.0
Bug: 250026064
Test: m rust
Change-Id: I7cbefca61dd002561f2e26040afe87defc702a10
Diffstat (limited to 'profcollectd')
-rw-r--r-- | profcollectd/libprofcollectd/report.rs | 2 | ||||
-rw-r--r-- | profcollectd/libprofcollectd/scheduler.rs | 4 | ||||
-rw-r--r-- | profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/profcollectd/libprofcollectd/report.rs b/profcollectd/libprofcollectd/report.rs index 69dff0c6..22789bd8 100644 --- a/profcollectd/libprofcollectd/report.rs +++ b/profcollectd/libprofcollectd/report.rs @@ -67,7 +67,7 @@ pub fn pack_report(profile: &Path, report: &Path, config: &Config) -> Result<Str let mut f = File::open(e)?; let mut buffer = Vec::new(); f.read_to_end(&mut buffer)?; - zip.write_all(&*buffer)?; + zip.write_all(&buffer)?; Ok(()) })?; zip.finish()?; diff --git a/profcollectd/libprofcollectd/scheduler.rs b/profcollectd/libprofcollectd/scheduler.rs index f58c4995..9af4d5d3 100644 --- a/profcollectd/libprofcollectd/scheduler.rs +++ b/profcollectd/libprofcollectd/scheduler.rs @@ -68,7 +68,7 @@ impl Scheduler { Ok(_) => break, Err(_) => { // Did not receive a termination signal, initiate trace event. - if check_space_limit(*TRACE_OUTPUT_DIR, &config).unwrap() { + if check_space_limit(&TRACE_OUTPUT_DIR, &config).unwrap() { trace_provider.lock().unwrap().trace( &TRACE_OUTPUT_DIR, "periodic", @@ -94,7 +94,7 @@ impl Scheduler { pub fn one_shot(&self, config: &Config, tag: &str) -> Result<()> { let trace_provider = self.trace_provider.clone(); - if check_space_limit(*TRACE_OUTPUT_DIR, config)? { + if check_space_limit(&TRACE_OUTPUT_DIR, config)? { trace_provider.lock().unwrap().trace(&TRACE_OUTPUT_DIR, tag, &config.sampling_period); } Ok(()) diff --git a/profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs b/profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs index f25f5ffc..14911ffb 100644 --- a/profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs +++ b/profcollectd/libprofcollectd/simpleperf_etm_trace_provider.rs @@ -42,7 +42,7 @@ impl TraceProvider for SimpleperfEtmTraceProvider { 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, ); |