ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/Convert-BER-XS/XS.pm
(Generate patch)

Comparing Convert-BER-XS/XS.pm (file contents):
Revision 1.28 by root, Sat Apr 20 15:37:27 2019 UTC vs.
Revision 1.29 by root, Sat Apr 20 15:39:13 2019 UTC

8 8
9 my $ber = ber_decode $buf, $Convert::BER::XS::SNMP_PROFILE 9 my $ber = ber_decode $buf, $Convert::BER::XS::SNMP_PROFILE
10 or die "unable to decode SNMP message"; 10 or die "unable to decode SNMP message";
11 11
12 # The above results in a data structure consisting of 12 # The above results in a data structure consisting of
13 # (class, tag, # constructed, data) 13 # (class, tag, flags, data)
14 # tuples. Below is such a message, SNMPv1 trap 14 # tuples. Below is such a message, SNMPv1 trap
15 # with a Cisco mac change notification. 15 # with a Cisco mac change notification.
16 # Did you know that Cisco is in the news almost 16 # Did you know that Cisco is in the news almost
17 # every week because of some backdoor password 17 # every week because of some backdoor password
18 # or other extremely stupid security bug? 18 # or other extremely stupid security bug?
303a ease-of-use exception, they usually also accept C<undef> instead of a 303a ease-of-use exception, they usually also accept C<undef> instead of a
304tuple reference, in which case they silently fail to match. 304tuple reference, in which case they silently fail to match.
305 305
306=over 306=over
307 307
308=item $bool = ber_is $tuple, $class, $tag, $constructed, $data 308=item $bool = ber_is $tuple, $class, $tag, $flags, $data
309 309
310This takes a BER C<$tuple> and matches its elements against the provided 310This takes a BER C<$tuple> and matches its elements against the provided
311values, all of which are optional - values that are either missing or 311values, all of which are optional - values that are either missing or
312C<undef> will be ignored, the others will be matched exactly (e.g. as if 312C<undef> will be ignored, the others will be matched exactly (e.g. as if
313you used C<==> or C<eq> (for C<$data>)). 313you used C<==> or C<eq> (for C<$data>)).

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines