… | |
… | |
130 | my $bin = unpack "b*", $msg; |
130 | my $bin = unpack "b*", $msg; |
131 | my $res = ""; |
131 | my $res = ""; |
132 | |
132 | |
133 | while ($bin =~ /\G($RE_dec)/cmog) { |
133 | while ($bin =~ /\G($RE_dec)/cmog) { |
134 | my $frag = $Net::Knuddels::Dictionary->{$1}; |
134 | my $frag = $Net::Knuddels::Dictionary->{$1}; |
135 | $frag = pack "b*", $bin =~ /\G.{16}/cmg ? && $1 if $frag eq "\\\\\\"; |
135 | $frag = pack "b*", $bin =~ /\G.{16}/cmg && $1 if $frag eq "\\\\\\"; |
136 | $res .= $frag; |
136 | $res .= $frag; |
137 | } |
137 | } |
138 | $bin =~ /\G(.*[^0].*)$/ and die "Net::Knuddels::Receiver: undecodable message tail '$1'"; |
138 | $bin =~ /\G(.*[^0].*)$/ and die "Net::Knuddels::Receiver: undecodable message tail '$1'"; |
139 | |
139 | |
140 | $self->feed_event (split /\0/, $res); |
140 | $self->feed_event (split /\0/, $res); |