r40717 - in /trunk/libtext-formattable-perl: Changes META.yml debian/README.source debian/changelog debian/control debian/patches/ debian/rules lib/Text/FormatTable.pm test.pl
carnil-guest at users.alioth.debian.org
carnil-guest at users.alioth.debian.org
Sat Jul 25 06:24:09 UTC 2009
Author: carnil-guest
Date: Sat Jul 25 06:24:02 2009
New Revision: 40717
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=40717
Log:
* New upstream release
* Drop zero-width.patch since fixed now upstream. Remove Build-Dependency
on quilt. Drop README.source which is explaining we used quilt.
Removed:
trunk/libtext-formattable-perl/debian/README.source
trunk/libtext-formattable-perl/debian/patches/
Modified:
trunk/libtext-formattable-perl/Changes
trunk/libtext-formattable-perl/META.yml
trunk/libtext-formattable-perl/debian/changelog
trunk/libtext-formattable-perl/debian/control
trunk/libtext-formattable-perl/debian/rules
trunk/libtext-formattable-perl/lib/Text/FormatTable.pm
trunk/libtext-formattable-perl/test.pl
Modified: trunk/libtext-formattable-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtext-formattable-perl/Changes?rev=40717&op=diff
==============================================================================
--- trunk/libtext-formattable-perl/Changes (original)
+++ trunk/libtext-formattable-perl/Changes Sat Jul 25 06:24:02 2009
@@ -1,4 +1,8 @@
Revision history for Perl extension Text::FormatTable.
+
+2009-07-24 (1.03)
+ * Fix for rt34546, uninitialized warning generated with a
+ zero-length column
2009-07-23 (1.02)
* Added support for ASCII color sequences. The escape codes are
Modified: trunk/libtext-formattable-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtext-formattable-perl/META.yml?rev=40717&op=diff
==============================================================================
--- trunk/libtext-formattable-perl/META.yml (original)
+++ trunk/libtext-formattable-perl/META.yml Sat Jul 25 06:24:02 2009
@@ -1,6 +1,6 @@
--- #YAML:1.0
name: Text-FormatTable
-version: 1.02
+version: 1.03
abstract: Format text tables
license: perl
author:
Modified: trunk/libtext-formattable-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtext-formattable-perl/debian/changelog?rev=40717&op=diff
==============================================================================
--- trunk/libtext-formattable-perl/debian/changelog (original)
+++ trunk/libtext-formattable-perl/debian/changelog Sat Jul 25 06:24:02 2009
@@ -1,3 +1,11 @@
+libtext-formattable-perl (1.03-1) UNRELEASED; urgency=low
+
+ * New upstream release
+ * Drop zero-width.patch since fixed now upstream. Remove Build-Dependency
+ on quilt. Drop README.source which is explaining we used quilt.
+
+ -- Salvatore Bonaccorso <salvatore.bonaccorso at gmail.com> Sat, 25 Jul 2009 08:22:11 +0200
+
libtext-formattable-perl (1.02-1) unstable; urgency=low
[ gregor herrmann ]
Modified: trunk/libtext-formattable-perl/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtext-formattable-perl/debian/control?rev=40717&op=diff
==============================================================================
--- trunk/libtext-formattable-perl/debian/control (original)
+++ trunk/libtext-formattable-perl/debian/control Sat Jul 25 06:24:02 2009
@@ -1,7 +1,7 @@
Source: libtext-formattable-perl
Section: perl
Priority: optional
-Build-Depends: debhelper (>= 7.0.50), quilt (>= 0.46-7)
+Build-Depends: debhelper (>= 7.0.50)
Build-Depends-Indep: perl (>= 5.8.0-7)
Maintainer: Debian Perl Group <pkg-perl-maintainers at lists.alioth.debian.org>
Uploaders: Damyan Ivanov <dmn at debian.org>,
Modified: trunk/libtext-formattable-perl/debian/rules
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtext-formattable-perl/debian/rules?rev=40717&op=diff
==============================================================================
--- trunk/libtext-formattable-perl/debian/rules (original)
+++ trunk/libtext-formattable-perl/debian/rules Sat Jul 25 06:24:02 2009
@@ -1,7 +1,7 @@
#!/usr/bin/make -f
%:
- dh --with quilt $@
+ dh $@
override_dh_auto_install:
dh_auto_install
Modified: trunk/libtext-formattable-perl/lib/Text/FormatTable.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtext-formattable-perl/lib/Text/FormatTable.pm?rev=40717&op=diff
==============================================================================
--- trunk/libtext-formattable-perl/lib/Text/FormatTable.pm (original)
+++ trunk/libtext-formattable-perl/lib/Text/FormatTable.pm Sat Jul 25 06:24:02 2009
@@ -2,9 +2,10 @@
use Carp;
use strict;
+use warnings;
use vars qw($VERSION);
-$VERSION = '1.02';
+$VERSION = '1.03';
=head1 NAME
@@ -48,14 +49,15 @@
my $l = _uncolorized_length $s;
$min = $l if not defined $min or $l > $min;
}
- return $min;
+ return $min ? $min : 1;
}
# width of $1 if not word-wrapped
sub _max_width($)
{
my $str = shift;
- return _uncolorized_length $str;
+ my $len = _uncolorized_length $str;
+ return $len ? $len : 1;
}
sub _max($$)
Modified: trunk/libtext-formattable-perl/test.pl
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtext-formattable-perl/test.pl?rev=40717&op=diff
==============================================================================
--- trunk/libtext-formattable-perl/test.pl (original)
+++ trunk/libtext-formattable-perl/test.pl Sat Jul 25 06:24:02 2009
@@ -1,7 +1,10 @@
use Test;
-BEGIN { plan tests => 4 };
+BEGIN { plan tests => 5 };
use Text::FormatTable;
ok(1); # If we made it this far, we're ok.
+
+use strict;
+use warnings;
{
my $table = Text::FormatTable->new('r| l l');
@@ -58,3 +61,14 @@
my ($rule) = ($output =~ /(=+)/);
ok(length($rule), length("foo bar bat"));
}
+
+# rt34546, warnings when column has zero length
+{
+ my $warning;
+ local $SIG{__WARN__} = sub { $warning = $_[0] };
+
+ my $table = Text::FormatTable->new('l l');
+ $table->head('foo', q{});
+ my $output = $table->render();
+ ok(not defined $warning);
+}
More information about the Pkg-perl-cvs-commits
mailing list