Petra Humann wrote:
> Is it possible to set a timeout value for getting the result
> of virus scanning in message_contains_virus_sophie?
Well, not directly, but you could do something like:
eval {
local $SIG{'ALRM'} = sub { die "Timeout\n"; };
alarm(10);
# Do your virus scanning
alarm(0);
};
if ($@ && $@ =~ /Timeout/) {
# Handle a timeout
} else {
# Handle the normal case
}
Regards,
David.
_______________________________________________
NOTE: If there is a disclaimer or other legal boilerplate in the above
message, it is NULL AND VOID. You may ignore it.
Visit http://www.mimedefang.org and http://www.roaringpenguin.com
MIMEDefang mailing list [email protected]
http://lists.roaringpenguin.com/mailman/listinfo/mimedefang