… | |
… | |
27 | no warnings; |
27 | no warnings; |
28 | |
28 | |
29 | use AnyEvent; |
29 | use AnyEvent; |
30 | |
30 | |
31 | BEGIN { |
31 | BEGIN { |
32 | our $VERSION = '1.11'; |
32 | our $VERSION = '1.12'; |
33 | our @ISA = qw(Exporter); |
33 | our @ISA = qw(Exporter); |
34 | |
34 | |
35 | require Exporter; |
35 | require Exporter; |
36 | #Exporter::export_ok_tags (keys %EXPORT_TAGS); |
36 | #Exporter::export_ok_tags (keys %EXPORT_TAGS); |
37 | |
37 | |
… | |
… | |
156 | Register a callback that is called for every received ping reply |
156 | Register a callback that is called for every received ping reply |
157 | (regardless of whether a ping is still in process or not and regardless of |
157 | (regardless of whether a ping is still in process or not and regardless of |
158 | whether the reply is actually a reply to a ping sent earlier). |
158 | whether the reply is actually a reply to a ping sent earlier). |
159 | |
159 | |
160 | The code reference gets a single parameter - an arrayref with an |
160 | The code reference gets a single parameter - an arrayref with an |
161 | entry for each received packet (replies are beign batched for greater |
161 | entry for each received packet (replies are being batched for greater |
162 | efficiency). Each packet is represented by an arrayref with three members: |
162 | efficiency). Each packet is represented by an arrayref with three members: |
163 | the source address (an octet string of either 4 (IPv4) or 16 (IPv6) octets |
163 | the source address (an octet string of either 4 (IPv4) or 16 (IPv6) octets |
164 | length), the payload as passed to C<icmp_ping> and the round trip time in |
164 | length), the payload as passed to C<icmp_ping> and the round trip time in |
165 | seconds. |
165 | seconds. |
166 | |
166 | |