In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/8235b1c2e77c454865e73bc098b667c3d9aa58a7?hp=8faf4f305a9ccdf8b6fdbfccb769dbb73e6b6d25>
- Log ----------------------------------------------------------------- commit 8235b1c2e77c454865e73bc098b667c3d9aa58a7 Author: Aaron Crane <[email protected]> Date: Wed Jan 4 15:42:32 2017 +0000 RT#130487: fix stack-management bug in Data::Dumper This was introduced when Data::Dumper acquired the ability to call B::Deparse from its XS implementation. ----------------------------------------------------------------------- Summary of changes: dist/Data-Dumper/Dumper.pm | 6 +++--- dist/Data-Dumper/Dumper.xs | 2 ++ dist/Data-Dumper/t/bugs.t | 13 ++++++++++++- 3 files changed, 17 insertions(+), 4 deletions(-) diff --git a/dist/Data-Dumper/Dumper.pm b/dist/Data-Dumper/Dumper.pm index 78efd44cae..00f6326ee1 100644 --- a/dist/Data-Dumper/Dumper.pm +++ b/dist/Data-Dumper/Dumper.pm @@ -10,7 +10,7 @@ package Data::Dumper; BEGIN { - $VERSION = '2.166'; # Don't forget to set version and release + $VERSION = '2.167'; # Don't forget to set version and release } # date in POD below! #$| = 1; @@ -1459,13 +1459,13 @@ be to use the C<Sortkeys> filter of Data::Dumper. Gurusamy Sarathy [email protected] -Copyright (c) 1996-2016 Gurusamy Sarathy. All rights reserved. +Copyright (c) 1996-2017 Gurusamy Sarathy. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. =head1 VERSION -Version 2.166 (November 14 2016) +Version 2.167 (January 4 2017) =head1 SEE ALSO diff --git a/dist/Data-Dumper/Dumper.xs b/dist/Data-Dumper/Dumper.xs index d288bbd8d5..0e7142e222 100644 --- a/dist/Data-Dumper/Dumper.xs +++ b/dist/Data-Dumper/Dumper.xs @@ -548,6 +548,8 @@ deparsed_output(pTHX_ SV *val) FREETMPS; + PUTBACK; + return text; } diff --git a/dist/Data-Dumper/t/bugs.t b/dist/Data-Dumper/t/bugs.t index 0a1ee8f7d1..5db82dad32 100644 --- a/dist/Data-Dumper/t/bugs.t +++ b/dist/Data-Dumper/t/bugs.t @@ -12,7 +12,7 @@ BEGIN { } use strict; -use Test::More tests => 23; +use Test::More tests => 24; use Data::Dumper; { @@ -168,4 +168,15 @@ SKIP: { } } +# RT#130487 - stack management bug in XS deparse +SKIP: { + skip "No XS available", 1 if !defined &Data::Dumper::Dumpxs; + sub rt130487_args { 0 + @_ } + my $code = sub {}; + local $Data::Dumper::Useperl = 0; + local $Data::Dumper::Deparse = 1; + my $got = rt130487_args( Dumper($code) ); + is($got, 1, "stack management in XS deparse works, rt 130487"); +} + # EOF -- Perl5 Master Repository
