projects
/
spider.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add missing K field definition
[spider.git]
/
perl
/
Msg.pm
diff --git
a/perl/Msg.pm
b/perl/Msg.pm
index 9251a1208f250c004217d0053a28d29db68a67e0..ceace3ca774c62603b22f2ab8577f8907c4af5f4 100644
(file)
--- a/
perl/Msg.pm
+++ b/
perl/Msg.pm
@@
-205,6
+205,7
@@
sub peerhost
$conn->{peerhost} ||= 'ax25' if $conn->ax25;
$conn->{peerhost} ||= $conn->{sock}->peerhost if $conn->{sock} && $conn->{sock}->isa('IO::Socket::INET');
$conn->{peerhost} ||= 'UNKNOWN';
$conn->{peerhost} ||= 'ax25' if $conn->ax25;
$conn->{peerhost} ||= $conn->{sock}->peerhost if $conn->{sock} && $conn->{sock}->isa('IO::Socket::INET');
$conn->{peerhost} ||= 'UNKNOWN';
+ $conn->{peerhost} =~ s/^::ffff://;
return $conn->{peerhost};
}
return $conn->{peerhost};
}
@@
-506,9
+507,9
@@
sub dequeue
my $conn = shift;
return if $conn->{disconnecting};
my $conn = shift;
return if $conn->{disconnecting};
- if ($conn->{msg} =~ /\
n
/) {
- my @lines = split /\
r?\n
/, $conn->{msg};
- if ($conn->{msg} =~ /\
n
$/) {
+ if ($conn->{msg} =~ /\
cJ
/) {
+ my @lines = split /\
cM?\cJ
/, $conn->{msg};
+ if ($conn->{msg} =~ /\
cM?\cJ
$/) {
delete $conn->{msg};
} else {
$conn->{msg} = pop @lines;
delete $conn->{msg};
} else {
$conn->{msg} = pop @lines;