зеркало из https://github.com/mozilla/gecko-dev.git
Place a 5 second timeout on the SMTP object -- this makes running setup bearable without an SMTP server (the default timeout is 2 minutes).
This commit is contained in:
Родитель
1454dc7651
Коммит
9868c69a29
|
@ -62,7 +62,7 @@ sub init {
|
|||
sub open {
|
||||
my $self = shift;
|
||||
{ local $^W = 0; # XXX shut up warnings in Net::SMTP
|
||||
$self->handle(Net::SMTP->new($self->host)); }
|
||||
$self->handle(Net::SMTP->new($self->host, 'Timeout' => 5)); } # XXX hard coded timeout
|
||||
if (not defined($self->handle)) {
|
||||
$self->warn(4, 'Could not create the SMTP handle');
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче