Skip to content

Commit

Permalink
use improved gix-diff API for better buffer handling
Browse files Browse the repository at this point in the history
  • Loading branch information
Byron committed Aug 21, 2024
1 parent 7f868d1 commit f944e49
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion gitoxide-core/src/hours/core.rs
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ pub fn spawn_tree_delta_threads<'scope>(
for chunk in rx {
for (commit_idx, parent_commit, commit) in chunk {
if let Some(cache) = cache.as_mut() {
cache.clear_resource_cache();
cache.clear_resource_cache_keep_allocation();
}
commits.fetch_add(1, Ordering::Relaxed);
if gix::interrupt::is_triggered() {
Expand Down
4 changes: 2 additions & 2 deletions gitoxide-core/src/query/engine/update.rs
Original file line number Diff line number Diff line change
Expand Up @@ -204,8 +204,8 @@ pub fn update(
Some(c) => c,
None => continue,
};
rewrite_cache.clear_resource_cache();
diff_cache.clear_resource_cache();
rewrite_cache.clear_resource_cache_keep_allocation();
diff_cache.clear_resource_cache_keep_allocation();
from.changes()?
.track_path()
.track_rewrites(Some(rewrites))
Expand Down
2 changes: 1 addition & 1 deletion gix/src/object/tree/diff/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ impl<'a, 'repo> Platform<'a, 'repo> {
lines_removed += counts.removals as u64;
}

resource_cache.clear_resource_cache();
resource_cache.clear_resource_cache_keep_allocation();
Ok::<_, std::convert::Infallible>(Action::Continue)
})?;

Expand Down

0 comments on commit f944e49

Please sign in to comment.