Skip to content

Commit 61820cb

Browse files
committed
Clippy
1 parent e157d5f commit 61820cb

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

objdiff-core/src/diff/display.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ pub fn display_row(
189189
let mut arg_idx = 0;
190190
let mut displayed_relocation = false;
191191
let analysis_result = if diff_config.show_data_flow {
192-
obj.get_flow_analysis_result(&resolved.symbol)
192+
obj.get_flow_analysis_result(resolved.symbol)
193193
} else {
194194
None
195195
};
@@ -217,7 +217,7 @@ pub fn display_row(
217217
}
218218
let data_flow_value =
219219
analysis_result.and_then(|result|
220-
result.as_ref().get_argument_value_at_address(
220+
result.get_argument_value_at_address(
221221
ins_ref.address, (arg_idx - 1) as u8));
222222
match (arg, data_flow_value, resolved.ins_ref.branch_dest) {
223223
// If we have a flow analysis result, always use that over anything else.

objdiff-core/src/obj/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -331,9 +331,9 @@ impl Object {
331331
pub fn get_flow_analysis_result(
332332
&self,
333333
symbol: &Symbol,
334-
) -> Option<&Box<dyn FlowAnalysisResult>> {
334+
) -> Option<&dyn FlowAnalysisResult> {
335335
let key = symbol.section.unwrap_or_default() as u64 + symbol.address;
336-
self.flow_analysis_results.get(&key)
336+
self.flow_analysis_results.get(&key).map(|result| result.as_ref())
337337
}
338338

339339
pub fn add_flow_analysis_result(

0 commit comments

Comments
 (0)