]> Sergey Matveev's repositories - public-inbox.git/blobdiff - script/public-inbox-edit
edit: unlink temporary file when done
[public-inbox.git] / script / public-inbox-edit
index 16d785294f49bcb79a62620af2a5548437ba508c..2e2c761620e154da65a395f6d9c6a12a756cb14f 100755 (executable)
@@ -121,7 +121,7 @@ $mids
 
 my $tmpl = 'public-inbox-edit-XXXXXX';
 foreach my $to_edit (values %$found) {
-       my ($edit_fh, $edit_fn) = tempfile($tmpl, TMPDIR => 1);
+       my ($edit_fh, $edit_fn) = tempfile($tmpl, TMPDIR => 1, UNLINK => 1);
        $edit_fh->autoflush(1);
        my ($ibx, $smsg) = @{$to_edit->[0]};
        my $old_raw = $ibx->msg_by_smsg($smsg);