From 676c765bdb6a5d4844d11806bdc86f2a38f7047e Mon Sep 17 00:00:00 2001 From: saal Date: Tue, 5 Jun 2007 08:36:47 +0000 Subject: suppression de warning --- src/SVG/SVG2zinc.pm | 8 +++++--- src/SVG/SVG2zinc/Backend/PerlClass.pm | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/SVG/SVG2zinc.pm b/src/SVG/SVG2zinc.pm index 31e4559..fb82c2b 100644 --- a/src/SVG/SVG2zinc.pm +++ b/src/SVG/SVG2zinc.pm @@ -1416,9 +1416,11 @@ sub polygon_ { sub path { my ($parser, $elementname, %attrs) = @_; push (@nameStack, $attrs{id}); - if($attrs{id} eq $targetName) - { - $includeFollowingItems = 1; + if (defined $attrs{id}) { + if($attrs{id} eq $targetName) + { + $includeFollowingItems = 1; + } } if( !$includeFollowingItems ) { diff --git a/src/SVG/SVG2zinc/Backend/PerlClass.pm b/src/SVG/SVG2zinc/Backend/PerlClass.pm index 4819b62..0f490b2 100644 --- a/src/SVG/SVG2zinc/Backend/PerlClass.pm +++ b/src/SVG/SVG2zinc/Backend/PerlClass.pm @@ -107,7 +107,7 @@ sub dtreatLines { $l =~ s/(\W)->/$1\$_zinc-> /g; } - if (defined @lines) + if (@lines) { my $rule = shift (@lines); push (@{$self -> {delayed_lines}}, $rule); -- cgit v1.1