r45078 - /trunk/dh-make-perl/lib/DhMakePerl.pm
dmn at users.alioth.debian.org
dmn at users.alioth.debian.org
Wed Sep 30 12:37:26 UTC 2009
Author: dmn
Date: Wed Sep 30 12:37:20 2009
New Revision: 45078
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=45078
Log:
fix substr outside of the string warning when finding examples
Modified:
trunk/dh-make-perl/lib/DhMakePerl.pm
Modified: trunk/dh-make-perl/lib/DhMakePerl.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/dh-make-perl/lib/DhMakePerl.pm?rev=45078&op=diff
==============================================================================
--- trunk/dh-make-perl/lib/DhMakePerl.pm (original)
+++ trunk/dh-make-perl/lib/DhMakePerl.pm Wed Sep 30 12:37:20 2009
@@ -987,6 +987,7 @@
$dir .= '/' unless $dir =~ m{/$};
find(
sub {
+ return unless length($_) > length($dir); # skip the directory itself
my $exampleguess = substr( $File::Find::name, length($dir) );
push( @examples,
( -d $exampleguess ? $exampleguess . '/*' : $exampleguess ) )
More information about the Pkg-perl-cvs-commits
mailing list