Hello community,
here is the log from the commit of package perl-Config-Tiny for openSUSE:Factory
checked in at Thu Mar 24 17:34:52 CET 2011.
--------
--- perl-Config-Tiny/perl-Config-Tiny.changes 2010-11-30 20:24:43.000000000 +0100
+++ /mounts/work_src_done/STABLE/perl-Config-Tiny/perl-Config-Tiny.changes 2011-03-24 09:42:16.000000000 +0100
@@ -1,0 +2,6 @@
+Thu Mar 24 08:38:30 UTC 2011 - pascal.bleser@opensuse.org
+
+- update to 2.14:
+ * fix RT#63080: module can write multiline values but not read them
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
Config-Tiny-2.13.tar.bz2
New:
----
Config-Tiny-2.14.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ perl-Config-Tiny.spec ++++++
--- /var/tmp/diff_new_pack.V4i4mA/_old 2011-03-24 17:34:38.000000000 +0100
+++ /var/tmp/diff_new_pack.V4i4mA/_new 2011-03-24 17:34:38.000000000 +0100
@@ -1,7 +1,7 @@
#
-# spec file for package perl-Config-Tiny (Version 2.13)
+# spec file for package perl-Config-Tiny
#
-# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -21,12 +21,12 @@
Name: perl-Config-Tiny
%define cpan_name Config-Tiny
Summary: Read/Write .ini style files with as little code as possible
-Version: 2.13
+Version: 2.14
Release: 1
License: GPL+ or Artistic
Group: Development/Libraries/Perl
Url: http://search.cpan.org/dist/Config-Tiny/
-#Source: http://www.cpan.org/authors/id/A/AD/ADAMK/Config-Tiny-2.13.tar.gz
+#Source: http://www.cpan.org/authors/id/A/AD/ADAMK/Config-Tiny-%{version}.tar.gz
Source: %{cpan_name}-%{version}.tar.bz2
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
@@ -48,6 +48,9 @@
Config::Tiny manpage does *not* preserve your comments, whitespace, or the
order of your config file.
+
+
+
Authors:
--------
Adam Kennedy
@@ -68,7 +71,7 @@
%perl_gen_filelist
%clean
-%{__rm} -rf $RPM_BUILD_ROOT
+%{?buildroot:%__rm -rf "%{buildroot}"}
%files -f %{name}.files
%defattr(-,root,root,-)
++++++ Config-Tiny-2.13.tar.bz2 -> Config-Tiny-2.14.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Config-Tiny-2.13/Changes new/Config-Tiny-2.14/Changes
--- old/Config-Tiny-2.13/Changes 2010-09-03 03:26:11.000000000 +0200
+++ new/Config-Tiny-2.14/Changes 2011-03-24 03:18:32.000000000 +0100
@@ -1,5 +1,9 @@
Revision history for Perl extension Config-Tiny
+2.14 Thu 24 Mar 2011
+ - Resolved #63080: module can write multiline values but not read them
+ - Removed -w from tests to allow tests with tainting on
+
2.13 Fri 3 Sep 2010
- Resolved #60703: Display glitch in Config::Tiny 2.12 POD
- Resolved #40585: member 'set;' doesn't exist
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Config-Tiny-2.13/META.yml new/Config-Tiny-2.14/META.yml
--- old/Config-Tiny-2.13/META.yml 2010-09-03 03:26:17.000000000 +0200
+++ new/Config-Tiny-2.14/META.yml 2011-03-24 03:18:38.000000000 +0100
@@ -1,6 +1,6 @@
--- #YAML:1.0
name: Config-Tiny
-version: 2.13
+version: 2.14
abstract: Read/Write .ini style files with as little code as possible
author:
- Adam Kennedy
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Config-Tiny-2.13/Makefile.PL new/Config-Tiny-2.14/Makefile.PL
--- old/Config-Tiny-2.13/Makefile.PL 2010-09-03 03:26:11.000000000 +0200
+++ new/Config-Tiny-2.14/Makefile.PL 2011-03-24 03:18:32.000000000 +0100
@@ -2,7 +2,7 @@
use vars qw{$VERSION};
BEGIN {
require 5.003_96;
- $VERSION = '2.13';
+ $VERSION = '2.14';
}
use ExtUtils::MakeMaker;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Config-Tiny-2.13/README new/Config-Tiny-2.14/README
--- old/Config-Tiny-2.13/README 2010-09-03 03:26:11.000000000 +0200
+++ new/Config-Tiny-2.14/README 2011-03-24 03:18:32.000000000 +0100
@@ -128,7 +128,7 @@
Config::Simple, Config::General, ali.as
COPYRIGHT
- Copyright 2002 - 2010 Adam Kennedy.
+ Copyright 2002 - 2011 Adam Kennedy.
This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Config-Tiny-2.13/lib/Config/Tiny.pm new/Config-Tiny-2.14/lib/Config/Tiny.pm
--- old/Config-Tiny-2.13/lib/Config/Tiny.pm 2010-09-03 03:26:11.000000000 +0200
+++ new/Config-Tiny-2.14/lib/Config/Tiny.pm 2011-03-24 03:18:32.000000000 +0100
@@ -5,7 +5,7 @@
use strict;
BEGIN {
require 5.004;
- $Config::Tiny::VERSION = '2.13';
+ $Config::Tiny::VERSION = '2.14';
$Config::Tiny::errstr = '';
}
@@ -97,15 +97,16 @@
# 1. Leading whitespace
# 2. Trailing whitespace
# 3. Newlines in section name
- if ( $section =~ /(?:^\s|\n|\s$)/s ) {
- return $self->_error(
- "Illegal whitespace in section name '$section'"
- );
- }
+ return $self->_error(
+ "Illegal whitespace in section name '$section'"
+ ) if $section =~ /(?:^\s|\n|\s$)/s;
my $block = $self->{$section};
$contents .= "\n" if length $contents;
$contents .= "[$section]\n" unless $section eq '_';
foreach my $property ( sort keys %$block ) {
+ return $self->_error(
+ "Illegal newlines in property '$section.$property'"
+ ) if $block->{$property} =~ /(?:\012|\015)/s;
$contents .= "$property=$block->{$property}\n";
}
}
@@ -268,7 +269,7 @@
=head1 COPYRIGHT
-Copyright 2002 - 2010 Adam Kennedy.
+Copyright 2002 - 2011 Adam Kennedy.
This program is free software; you can redistribute
it and/or modify it under the same terms as Perl itself.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Config-Tiny-2.13/t/01_compile.t new/Config-Tiny-2.14/t/01_compile.t
--- old/Config-Tiny-2.13/t/01_compile.t 2010-09-03 03:26:11.000000000 +0200
+++ new/Config-Tiny-2.14/t/01_compile.t 2011-03-24 03:18:32.000000000 +0100
@@ -1,4 +1,4 @@
-#!/usr/bin/perl -w
+#!/usr/bin/perl
# Compile testing for Config::Tiny
@@ -8,9 +8,6 @@
$^W = 1;
}
-use Test::More tests => 2;
+use Test::More tests => 1;
-ok( $] >= 5.004, "Your perl is new enough" );
use_ok('Config::Tiny');
-
-exit(0);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Config-Tiny-2.13/t/02_main.t new/Config-Tiny-2.14/t/02_main.t
--- old/Config-Tiny-2.13/t/02_main.t 2010-09-03 03:26:11.000000000 +0200
+++ new/Config-Tiny-2.14/t/02_main.t 2011-03-24 03:18:32.000000000 +0100
@@ -1,4 +1,4 @@
-#!/usr/bin/perl -w
+#!/usr/bin/perl
# Main testing script for Config::Tiny
@@ -8,25 +8,22 @@
$^W = 1;
}
-use UNIVERSAL;
use Test::More tests => 33;
+use Config::Tiny ();
+use UNIVERSAL ();
use vars qw{$VERSION};
BEGIN {
- $VERSION = '2.13';
+ $VERSION = '2.14';
}
# Check their perl version
-BEGIN {
- ok( $] >= 5.004, "Your perl is new enough" );
- use_ok('Config::Tiny');
-}
is( $Config::Tiny::VERSION, $VERSION, 'Loaded correct version of Config::Tiny' );
# Test trivial creation
-my $Trivial = Config::Tiny->new();
+my $Trivial = Config::Tiny->new;
ok( $Trivial, '->new returns true' );
ok( ref $Trivial, '->new returns a reference' );
# Legitimate use of UNIVERSAL::isa
@@ -46,31 +43,33 @@
my $expected = {
'_' => {
root => 'something',
- },
+ },
section => {
one => 'two',
Foo => 'Bar',
this => 'Your Mother!',
blank => '',
- },
+ },
'Section Two' => {
'something else' => 'blah',
'remove' => 'whitespace',
- },
- };
+ },
+};
bless $expected, 'Config::Tiny';
is_deeply( $Config, $expected, 'Config structure matches expected' );
# Add some stuff to the trivial config and check write_string() for it
-$Trivial->{_} = { root1 => 'root2' };
+$Trivial->{_} = {
+ root1 => 'root2',
+};
$Trivial->{section} = {
foo => 'bar',
this => 'that',
blank => '',
- };
+};
$Trivial->{section2} = {
'this little piggy' => 'went to market'
- };
+};
my $string = <read_string('');
-isa_ok( $Empty, 'Config::Tiny' );
-is( scalar(keys %$Empty), 0, 'Config::Tiny object from empty string, is empty' );
+SCOPE: {
+ # Reading in an empty file, or a defined but zero length string, should yield
+ # a valid, but empty, object.
+ my $Empty = Config::Tiny->read_string('');
+ isa_ok( $Empty, 'Config::Tiny' );
+ is( scalar(keys %$Empty), 0, 'Config::Tiny object from empty string, is empty' );
}
-
-
-{
-# A Section header like [ section ] doesn't end up at ->{' section '}.
-# Trim off whitespace from the section header.
-my $string = <<'END';
+SCOPE: {
+ # A Section header like [ section ] doesn't end up at ->{' section '}.
+ # Trim off whitespace from the section header.
+ my $string = <<'END_CONFIG';
# The need to trim off whitespace makes a lot more sense
# when you are trying to maximise readability.
[ /path/to/file.txt ]
@@ -145,14 +142,37 @@
[section3 ]
this=that
-END
+END_CONFIG
-my $Trim = Config::Tiny->read_string($string);
-isa_ok( $Trim, 'Config::Tiny' );
-ok( exists $Trim->{'/path/to/file.txt'}, 'First section created' );
-is( $Trim->{'/path/to/file.txt'}->{this}, 'that', 'First section created properly' );
-ok( exists $Trim->{section2}, 'Second section created' );
-is( $Trim->{section2}->{this}, 'that', 'Second section created properly' );
-ok( exists $Trim->{section3}, 'Third section created' );
-is( $Trim->{section3}->{this}, 'that', 'Third section created properly' );
+ my $Trim = Config::Tiny->read_string($string);
+ isa_ok( $Trim, 'Config::Tiny' );
+ ok( exists $Trim->{'/path/to/file.txt'}, 'First section created' );
+ is( $Trim->{'/path/to/file.txt'}->{this}, 'that', 'First section created properly' );
+ ok( exists $Trim->{section2}, 'Second section created' );
+ is( $Trim->{section2}->{this}, 'that', 'Second section created properly' );
+ ok( exists $Trim->{section3}, 'Third section created' );
+ is( $Trim->{section3}->{this}, 'that', 'Third section created properly' );
+}
+
+
+
+
+
+######################################################################
+# Refuse to write config files with newlines in them
+
+SCOPE: {
+ my $newline = Config::Tiny->new;
+ $newline->{_}->{string} = "foo\nbar";
+ local $@;
+ my $output = undef;
+ eval {
+ $output = $newline->write_string;
+ };
+ is( $output, undef, '->write_string returns undef on newlines' );
+ is(
+ Config::Tiny->errstr,
+ "Illegal newlines in property '_.string'",
+ '->errstr returns expected error',
+ );
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Config-Tiny-2.13/xt/pmv.t new/Config-Tiny-2.14/xt/pmv.t
--- old/Config-Tiny-2.13/xt/pmv.t 2010-09-03 03:26:11.000000000 +0200
+++ new/Config-Tiny-2.14/xt/pmv.t 2011-03-24 03:18:32.000000000 +0100
@@ -9,7 +9,7 @@
}
my @MODULES = (
- 'Perl::MinimumVersion 1.25',
+ 'Perl::MinimumVersion 1.27',
'Test::MinimumVersion 0.101080',
);
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org