"Use of uninitialized value in pattern match" warning when deserialising an AMF message with
headers, as deserialise creates a new MessageHeader object with no args but new() does a
pattern match on $required.
example fix:
package AMF::Connection::MessageHeader;
use strict;
use Carp;
sub new {
my $proto = shift;
my $class = ref($proto) || $proto;
my $self = {};
if ( @_ ) {
my ($name, $value, $required) = @_;
$self->{'name'} = $name;
$self->{'value'} = $value;
$self->{'required'} = ($required=~m/(1|yes)/) ? 1 : 0;
}
return bless($self, $class);
};