… | |
… | |
127 | Scalar::Util::weaken (my $self = $self); |
127 | Scalar::Util::weaken (my $self = $self); |
128 | |
128 | |
129 | my $config = $AnyEvent::MP::Kernel::CONFIG; |
129 | my $config = $AnyEvent::MP::Kernel::CONFIG; |
130 | |
130 | |
131 | my $timeout = $config->{monitor_timeout}; |
131 | my $timeout = $config->{monitor_timeout}; |
132 | my $lframing = $config->{data_format}; |
132 | my $lframing = $config->{framing_format}; |
133 | my $auth_snd = $config->{auth_offer}; |
133 | my $auth_snd = $config->{auth_offer}; |
134 | my $auth_rcv = $config->{auth_accept}; |
134 | my $auth_rcv = $config->{auth_accept}; |
135 | |
135 | |
136 | $self->{secret} = $config->{secret} |
136 | $self->{secret} = $config->{secret} |
137 | unless exists $self->{secret}; |
137 | unless exists $self->{secret}; |
… | |
… | |
301 | $self->{remote_greeting}{untrusted} = 1 |
301 | $self->{remote_greeting}{untrusted} = 1 |
302 | if $auth_method eq "tls_anon"; |
302 | if $auth_method eq "tls_anon"; |
303 | |
303 | |
304 | $self->connected; |
304 | $self->connected; |
305 | |
305 | |
306 | if ($protocol eq "aemp") { |
306 | if ($protocol eq "aemp" and $self->{hdl}) { |
307 | # listener-less node need to continuously probe |
307 | # listener-less node need to continuously probe |
308 | unless (@$AnyEvent::MP::Kernel::LISTENER) { |
308 | unless (@$AnyEvent::MP::Kernel::LISTENER) { |
309 | $self->{hdl}->wtimeout ($timeout); |
309 | $self->{hdl}->wtimeout ($timeout); |
310 | $self->{hdl}->on_wtimeout (sub { $self->send ([]) }); |
310 | $self->{hdl}->on_wtimeout (sub { $self->send ([]) }); |
311 | } |
311 | } |