r28409 - in /trunk/libipc-system-simple-perl: Changes MANIFEST META.yml debian/changelog debian/control lib/IPC/System/Simple.pm t/08_core.t t/14_uninitialised.t
gregoa at users.alioth.debian.org
gregoa at users.alioth.debian.org
Fri Dec 19 20:04:07 UTC 2008
Author: gregoa
Date: Fri Dec 19 20:04:04 2008
New Revision: 28409
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=28409
Log:
* New upstream release, contains a workaround for an oddity in Perl 5.10
that can be seen in a test (cf. #509041).
* Add libbsd-resource-perl to Build-Depends-Indep to enable this test.
Added:
trunk/libipc-system-simple-perl/t/14_uninitialised.t
- copied unchanged from r28408, branches/upstream/libipc-system-simple-perl/current/t/14_uninitialised.t
Modified:
trunk/libipc-system-simple-perl/Changes
trunk/libipc-system-simple-perl/MANIFEST
trunk/libipc-system-simple-perl/META.yml
trunk/libipc-system-simple-perl/debian/changelog
trunk/libipc-system-simple-perl/debian/control
trunk/libipc-system-simple-perl/lib/IPC/System/Simple.pm
trunk/libipc-system-simple-perl/t/08_core.t
Modified: trunk/libipc-system-simple-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libipc-system-simple-perl/Changes?rev=28409&op=diff
==============================================================================
--- trunk/libipc-system-simple-perl/Changes (original)
+++ trunk/libipc-system-simple-perl/Changes Fri Dec 19 20:04:04 2008
@@ -1,4 +1,34 @@
Revision history for Perl extension IPC::System::Simple.
+
+1.17 Fri Dec 19 00:45:16 AUSEDT 2008
+ * TEST: Tests to ensure that passing undefined values to
+ systemx() do not produce malformed errors, but instead
+ well-formed errors. Many thanks to Nadim Khemir for
+ spotting this. RT #41149.
+
+ * BUGFIX: Workaround for a bug under Perl 5.10 where on
+ some platforms coredumps were not being reported in $?.
+ Many thanks to the Debian Perl folks for finding this,
+ particularly Gregor Herrmann.
+
+ * TEST: Better diagnostics from t/08_core.t.
+
+ * TEST: t/08_core.t now cleans up its core files after running.
+ Thanks to Gregor Herrmann for spotting this.
+
+ * TEST: t/08_core.t is now a main test, rather than an
+ author-only test.
+
+ * BUGFIX: Attempting to call an undefined command is now
+ a fatal error.
+
+ * VERSION: Since ISS is now very stable, and provides a
+ significantly improved interface to the default system()
+ command, the major version number has been incremented.
+
+ There are no incompatible changes with previous version.
+ The increment of the major version number is to indicate
+ stability only.
0.16 Sun Sep 14 11:29:17 AUSEST 2008
* DOCUMENTATION: Updated documentation on $EXITVAL to provide
Modified: trunk/libipc-system-simple-perl/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libipc-system-simple-perl/MANIFEST?rev=28409&op=diff
==============================================================================
--- trunk/libipc-system-simple-perl/MANIFEST (original)
+++ trunk/libipc-system-simple-perl/MANIFEST Fri Dec 19 20:04:04 2008
@@ -28,6 +28,7 @@
t/11_newlines.t
t/12_systemx.t
t/13_exports.t
+t/14_uninitialised.t
t/critic.t
t/exiter.pl
t/internal.t
Modified: trunk/libipc-system-simple-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libipc-system-simple-perl/META.yml?rev=28409&op=diff
==============================================================================
--- trunk/libipc-system-simple-perl/META.yml (original)
+++ trunk/libipc-system-simple-perl/META.yml Fri Dec 19 20:04:04 2008
@@ -29,4 +29,4 @@
bugtracker: http://rt.cpan.org/NoAuth/Bugs.html?Dist=IPC-System-Simple
license: http://dev.perl.org/licenses/
repository: http://github.com/pfenwick/ipc-system-simple/tree/master
-version: 0.16
+version: 1.17
Modified: trunk/libipc-system-simple-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libipc-system-simple-perl/debian/changelog?rev=28409&op=diff
==============================================================================
--- trunk/libipc-system-simple-perl/debian/changelog (original)
+++ trunk/libipc-system-simple-perl/debian/changelog Fri Dec 19 20:04:04 2008
@@ -1,3 +1,11 @@
+libipc-system-simple-perl (0.17-1) UNRELEASED; urgency=low
+
+ * New upstream release, contains a workaround for an oddity in Perl 5.10
+ that can be seen in a test (cf. #509041).
+ * Add libbsd-resource-perl to Build-Depends-Indep to enable this test.
+
+ -- gregor herrmann <gregoa at debian.org> Fri, 19 Dec 2008 20:59:31 +0100
+
libipc-system-simple-perl (0.16-1) unstable; urgency=low
* Initial Release. (Closes: #508507)
Modified: trunk/libipc-system-simple-perl/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libipc-system-simple-perl/debian/control?rev=28409&op=diff
==============================================================================
--- trunk/libipc-system-simple-perl/debian/control (original)
+++ trunk/libipc-system-simple-perl/debian/control Fri Dec 19 20:04:04 2008
@@ -3,7 +3,7 @@
Priority: optional
Build-Depends: debhelper (>= 7)
Build-Depends-Indep: perl (>= 5.6.0-12), libtest-pod-perl,
- libtest-pod-coverage-perl, libtest-perl-critic-perl
+ libtest-pod-coverage-perl, libtest-perl-critic-perl, libbsd-resource-perl
Maintainer: Debian Perl Group <pkg-perl-maintainers at lists.alioth.debian.org>
Uploaders: Jeremiah C. Foster <jeremiah at jeremiahfoster.com>
Standards-Version: 3.8.0
Modified: trunk/libipc-system-simple-perl/lib/IPC/System/Simple.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libipc-system-simple-perl/lib/IPC/System/Simple.pm?rev=28409&op=diff
==============================================================================
--- trunk/libipc-system-simple-perl/lib/IPC/System/Simple.pm (original)
+++ trunk/libipc-system-simple-perl/lib/IPC/System/Simple.pm Fri Dec 19 20:04:04 2008
@@ -39,6 +39,8 @@
use constant FAIL_SIGNAL => q{"%s" died to signal "%s" (%d)%s};
use constant FAIL_BADEXIT => q{"%s" unexpectedly returned exit value %d};
+use constant FAIL_UNDEF => q{%s called with undefined command};
+
use constant FAIL_POSIX => q{IPC::System::Simple does not understand the POSIX error '%s'. Please check http://search.cpan.org/perldoc?IPC::System::Simple to see if there is an updated version. If not please report this as a bug to http://rt.cpan.org/Public/Bug/Report.html?Queue=IPC-System-Simple};
# On Perl's older than 5.8.x we can't assume that there'll be a
@@ -61,7 +63,7 @@
$EXITVAL EXIT_ANY
);
-our $VERSION = '0.16';
+our $VERSION = '1.17';
our $EXITVAL = -1;
my @Signal_from_number = split(' ', $Config{sig_name});
@@ -95,15 +97,26 @@
# many systems define it. Check the POSIX module in the hope that
# it may actually be there.
+
+# TODO: Ideally, $NATIVE_WCOREDUMP should be a constant.
+
+my $NATIVE_WCOREDUMP;
+
eval { POSIX::WCOREDUMP(1); };
if ($@ =~ UNDEFINED_POSIX_RE) {
*WCOREDUMP = sub { $_[0] & 128 };
+ $NATIVE_WCOREDUMP = 0;
} elsif ($@) {
croak sprintf FAIL_POSIX, $@;
} else {
# POSIX actually has it defined! Huzzah!
*WCOREDUMP = \&POSIX::WCOREDUMP;
+ $NATIVE_WCOREDUMP = 1;
+}
+
+sub _native_wcoredump {
+ return $NATIVE_WCOREDUMP;
}
# system simply calls run
@@ -469,6 +482,16 @@
my $coredump = WCOREDUMP($child_error);
+ # There's a bug in perl 5.10.0 where if the system
+ # does not provide a native WCOREDUMP, then $? will
+ # never contain coredump information. This code
+ # checks to see if we have the bug, and works around
+ # it if needed.
+
+ if ($] >= 5.010 and not $NATIVE_WCOREDUMP) {
+ $coredump ||= WCOREDUMP( ${^CHILD_ERROR_NATIVE} );
+ }
+
if ($child_error == -1) {
croak sprintf(FAIL_START, $command, $!);
@@ -530,6 +553,10 @@
}
my $command = shift(@_);
+
+ if (not defined $command) {
+ croak sprintf( FAIL_UNDEF, $caller );
+ }
return ($valid_returns,$command, at _);
@@ -894,6 +921,12 @@
If not, please file a bug report according to the L</Reporting bugs> section
below.
+=item IPC::System::Simple::%s called with undefined command
+
+You've passed the undefined value as a command to be executed.
+While this is a very Zen-like action, it's not supported by
+Perl's current implementation.
+
=back
=head1 DEPENDENCIES
Modified: trunk/libipc-system-simple-perl/t/08_core.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libipc-system-simple-perl/t/08_core.t?rev=28409&op=diff
==============================================================================
--- trunk/libipc-system-simple-perl/t/08_core.t (original)
+++ trunk/libipc-system-simple-perl/t/08_core.t Fri Dec 19 20:04:04 2008
@@ -6,15 +6,11 @@
use constant SIGABRT => 6;
BEGIN {
- if (not $ENV{TEST_AUTHOR}) {
- plan skip_all => 'Author test. Set $ENV{TEST_AUTHOR} to true to run.'
- }
+ eval { require BSD::Resource; BSD::Resource->import() };
- eval { require BSD::Resource; BSD::Resource->import() };
-
- if ($@) {
- plan skip_all => "BSD::Resource required for coredump tests";
- }
+ if ($@) {
+ plan skip_all => "BSD::Resource required for coredump tests";
+ }
}
plan tests => 3;
@@ -41,6 +37,8 @@
run([1],$perl_path, 'signaler.pl', SIGABRT);
};
- like($@, qr/died to signal/);
- like($@, qr/dumped core/);
+ like($@, qr/died to signal/, "Signal caught, \$? = $?");
+ like($@, qr/dumped core/, "Coredump caught, \$? = $?");
+
+ unlink('core'); # Clean up our core file, if it exists.
}
More information about the Pkg-perl-cvs-commits
mailing list