my $f = delete $self->{filename};
if (!-f $f) { # SQLite defaults mode to 0644, we want 0666
if ($rw) {
+ require PublicInbox::Spawn;
open my $fh, '+>>', $f or die "failed to open $f: $!";
+ PublicInbox::Spawn::nodatacow_fd(fileno($fh));
+ my $j = "$f-journal";
+ open $fh, '+>>', $j or die "failed to open $j: $!";
+ PublicInbox::Spawn::nodatacow_fd(fileno($fh));
} else {
$self->{filename} = $f; # die on stat() below:
}