Subject: | unknown AllocNamedColor vs perl -w |
Date: | Wed, 23 Jun 2010 08:37:58 +1000 |
To: | bug-X11-Protocol [...] rt.cpan.org |
From: | Kevin Ryde <user42 [...] zip.com.au> |
With X11::Protocol 0.56 and recent debian i386 perl 5.10.1 a program
use strict;
use warnings;
use X11::Protocol;
my $X = X11::Protocol->new;
$X->AllocNamedColor ($X->{'default_colormap'}, 'nosuchcolour');
run as
perl -w foo.pl
prints
Use of uninitialized value in numeric eq (==) at /usr/share/perl5/X11/Protocol.pm line 588.
Protocol error: bad 15 (Name); Sequence Number 3
Opcode (85, 0) = AllocNamedColor
at foo.pl line 5
The protocol error is expected due to no such colour, but I hoped it
wouldn't also give an "uninitialized value" warning under the -w option.