Skip to content

Commit

Permalink
chore: adds expect to catch errors in mac engine
Browse files Browse the repository at this point in the history
  • Loading branch information
clearlysid committed May 19, 2024
1 parent 39a67aa commit 51ffb31
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scap/src/capturer/engine/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ impl Engine {
#[cfg(target_os = "macos")]
{
// self.mac.add_output(Capturer::new(tx));
self.mac.start_capture();
self.mac.start_capture().expect("Failed to start capture");
}

#[cfg(target_os = "windows")]
Expand All @@ -75,7 +75,7 @@ impl Engine {
pub fn stop(&mut self) {
#[cfg(target_os = "macos")]
{
self.mac.stop_capture();
self.mac.stop_capture().expect("Failed to stop capture");
}

#[cfg(target_os = "windows")]
Expand Down

0 comments on commit 51ffb31

Please sign in to comment.