summaryrefslogtreecommitdiff
path: root/plugins/warp/src/plugin
diff options
context:
space:
mode:
authorMason Reed <mason@vector35.com>2024-10-30 17:58:32 -0400
committerMason Reed <mason@vector35.com>2024-11-03 12:51:09 -0500
commit5d8952c340ee91d240a80275f6d993a621d76a6f (patch)
tree298c23ef0faebcfc97a6d8417e8b47346fd6803c /plugins/warp/src/plugin
parent5306314b6882f4ca98b36ee2a69c8d886464dcbf (diff)
WARP: Cleanup find from function guid command
Diffstat (limited to 'plugins/warp/src/plugin')
-rw-r--r--plugins/warp/src/plugin/find.rs11
1 files changed, 7 insertions, 4 deletions
diff --git a/plugins/warp/src/plugin/find.rs b/plugins/warp/src/plugin/find.rs
index 6d6c5bc1..3a14f7fb 100644
--- a/plugins/warp/src/plugin/find.rs
+++ b/plugins/warp/src/plugin/find.rs
@@ -27,11 +27,10 @@ impl Command for FindFunctionFromGUID {
thread::spawn(move || {
let background_task = binaryninja::backgroundtask::BackgroundTask::new(
format!("Searching functions for GUID... {}", searched_guid),
- true,
+ false,
)
.unwrap();
- // TODO: While background_task has not finished.
let matched = funcs
.par_iter()
.filter_map(|func| {
@@ -43,8 +42,12 @@ impl Command for FindFunctionFromGUID {
.filter(|(_func, guid)| guid.eq(&searched_guid))
.collect::<Vec<_>>();
- for (func, _) in matched {
- log::info!("Match found at function... 0x{:0x}", func.start());
+ if matched.is_empty() {
+ log::info!("No matches found for GUID... {}", searched_guid);
+ } else {
+ for (func, _) in matched {
+ log::info!("Match found at function... 0x{:0x}", func.start());
+ }
}
background_task.finish();