]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/Import.pm
v2: parallelize Xapian indexing
[public-inbox.git] / lib / PublicInbox / Import.pm
index 1a2698a75d609aea4162075e312a791f1c9041c0..b650e4ef1a1dc9d6a610a812cdca9022b71f53d3 100644 (file)
@@ -280,14 +280,12 @@ sub add {
        $self->{bytes_added} += $n;
        print $w "blob\nmark :$blob\ndata ", $n, "\n" or wfail;
        print $w $str, "\n" or wfail;
-       $str = undef;
 
        # v2: we need this for Xapian
        if ($self->{want_object_id}) {
                chomp($self->{last_object_id} = $self->get_mark(":$blob"));
-               $self->{last_object_size} = $n;
+               $self->{last_object} = [ $n, \$str ];
        }
-
        my $ref = $self->{ref};
        my $commit = $self->{mark}++;
        my $parent = $tip =~ /\A:/ ? $tip : undef;