about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong (Contractor, The Linux Foundation) <e@80x24.org>2018-03-26 18:19:31 +0000
committerEric Wong (Contractor, The Linux Foundation) <e@80x24.org>2018-03-27 02:34:25 +0000
commit2f5bb422a75f38e9c2fdca5d526fd8832ca9de45 (patch)
treeb5e7fcdcb46d29074b111d0dec9ca76cd68ae7e8
parent007cb8774e7013e2aaca32003bbd1653e3d8582f (diff)
downloadpublic-inbox-2f5bb422a75f38e9c2fdca5d526fd8832ca9de45.tar.gz
This should help us detect bugs sooner in case we have
space waste problems.
-rw-r--r--lib/PublicInbox/SearchIdx.pm4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/PublicInbox/SearchIdx.pm b/lib/PublicInbox/SearchIdx.pm
index 7ac16ec2..446cfb0d 100644
--- a/lib/PublicInbox/SearchIdx.pm
+++ b/lib/PublicInbox/SearchIdx.pm
@@ -561,6 +561,10 @@ sub link_and_save {
                         1;
                 });
         }
+        if ($vivified > 1) {
+                my $id = '<'.join('> <', @$mids).'>';
+                warn "BUG: vivified multiple ($vivified) ghosts for $id\n";
+        }
         # not really important, but we return any vivified ghost docid, here:
         return $doc_id if defined $doc_id;
         link_doc($self, $doc, $refs, $old_tid);