Skip to content

Commit

Permalink
Add build command before minimize
Browse files Browse the repository at this point in the history
  • Loading branch information
louismerlin committed Jan 17, 2024
1 parent a09fc98 commit ab39ed8
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/bin/cargo-ziggy/minimize.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
use crate::{find_target, FuzzingEngines, Minimize};
use crate::{find_target, Build, FuzzingEngines, Minimize};
use anyhow::{Context, Result};
use std::{env, fs::File, process, thread, time::Duration};

impl Minimize {
pub fn minimize(&mut self) -> Result<(), anyhow::Error> {
let build = Build {
no_afl: self.engine == FuzzingEngines::Honggfuzz,
no_honggfuzz: self.engine == FuzzingEngines::AFLPlusPlus,
};
build.build().context("Failed to build the fuzzers")?;

self.target =
find_target(&self.target).context("⚠️ couldn't find target when minimizing")?;

Expand Down

0 comments on commit ab39ed8

Please sign in to comment.