diff options
Diffstat (limited to 'src/filters.cc')
-rw-r--r-- | src/filters.cc | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/filters.cc b/src/filters.cc index 6c4c0f48..0c45d356 100644 --- a/src/filters.cc +++ b/src/filters.cc @@ -107,6 +107,9 @@ void truncate_xacts::flush() void truncate_xacts::operator()(post_t& post) { + if (completed) + return; + if (last_xact != post.xact) { if (last_xact) xacts_seen++; @@ -114,8 +117,11 @@ void truncate_xacts::operator()(post_t& post) } if (tail_count == 0 && head_count > 0 && - static_cast<int>(xacts_seen) >= head_count) + static_cast<int>(xacts_seen) >= head_count) { + flush(); + completed = true; return; + } posts.push_back(&post); } |