]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/Msgmap.pm
msgmap: tmp_clone: use in-memory journal
[public-inbox.git] / lib / PublicInbox / Msgmap.pm
index 5fe14383ac484a79e1b279b718e28db68b5449d4..a2ffe7203e74c026af8675fea0922c026740f7f7 100644 (file)
@@ -70,6 +70,7 @@ sub tmp_clone {
        $self->{dbh}->sqlite_backup_to_file($fn);
        my $tmp = ref($self)->new_file($fn, 1);
        $tmp->{dbh}->do('PRAGMA synchronous = OFF');
+       $tmp->{dbh}->do('PRAGMA journal_mode = MEMORY');
        $tmp->{tmp_name} = $fn; # SQLite won't work if unlinked, apparently
        $tmp->{pid} = $$;
        close $fh or die "failed to close $fn: $!";