Skip to content

Commit

Permalink
Add destructor
Browse files Browse the repository at this point in the history
  • Loading branch information
iesahin committed Dec 30, 2023
1 parent ddd9589 commit 568b017
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion core/src/util/file.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! Core file operations
//! Core file operationscorefil
use cached::proc_macro::cached;
use cached::UnboundCache;
use glob::Pattern as GlobPattern;
Expand Down Expand Up @@ -230,6 +230,13 @@ impl XvcPathMetadataProvider {
}
}

impl Drop for XvcPathMetadataProvider {
/// Stop the background thread when quit
fn drop(&mut self) {
self.stop().unwrap();
}
}

/// A parallel directory walker.
/// It starts from `start_dir` and sends [PathMetadata] by traversing all child directories.
/// It uses [xvc_walker::walk_parallel] after building an empty [IgnoreRules].
Expand Down

0 comments on commit 568b017

Please sign in to comment.