Skip to content

Commit

Permalink
fix memory leak
Browse files Browse the repository at this point in the history
  • Loading branch information
Jon committed Jan 28, 2024
1 parent 6d1a387 commit 37ff643
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sampling/include/ebpps_sample_impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,9 @@ template<typename TT>
void ebpps_sample<T,A>::replace_content(TT&& item, double theta) {
c_ = theta;
data_.clear();
partial_item_.reset();
if (theta == 1.0) {
data_.emplace_back(std::forward<TT>(item));
partial_item_.reset();
} else {
partial_item_.emplace(std::forward<TT>(item));
}
Expand Down

0 comments on commit 37ff643

Please sign in to comment.