|
From: Mark M. <Mar...@ij...> - 2010-03-15 20:37:15
|
.< File::Temp::tempfile("discl_temp_${mail_id}_XXXXX", SUFFIX => '.txt',
.< DIR => $Amavis::Conf::helpers_home);
.> File::Temp::tempfile("discl_temp_${mail_id}_XXXXX", SUFFIX => '.txt',
.> DIR => $Amavis::Conf::helpers_home, UNLINK => 1);
If you want deletion of temporary files before the process terminates,
it can be done explicitly in a hook such as mail_done(), just make sure
the $filename variable is visible there.
sub mail_done {
my($self,$conn,$msginfo) = @_;
if (defined $filename) {
unlink($filename) or die "Can't remove $filename: $!";
}
}
Mark
|