Skip Menu |

This queue is for tickets about the Apache-Test CPAN distribution.

Report information
The Basics
Id: 95805
Status: rejected
Priority: 0/
Queue: Apache-Test

People
Owner: Nobody in particular
Requestors: TIMB [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: libapreq2 make test fails due to "Use of each() on hash after insertion" in Apache/TestSSLCA.pm
[ error] configure() has failed: Use of each() on hash after insertion without resetting hash iterator results in undefined behavior, Perl interpreter: 0xce3010 at /home/tim/trunk/cpan/cpan-5.018/lib/perl5/x86_64-linux-thread-multi/Apache/TestSSLCA.pm line 103. Compilation failed in require at /home/tim/trunk/cpan/cpan-5.018/lib/perl5/x86_64-linux-thread-multi/Apache/TestConfig.pm line 1474. This patch fixes it: --- a/cpan-5.018/lib/perl5/x86_64-linux-thread-multi/Apache/TestSSLCA.pm +++ b/cpan-5.018/lib/perl5/x86_64-linux-thread-multi/Apache/TestSSLCA.pm @@ -100,8 +100,9 @@ my $cert_dn = { }; #generate DSA versions of the server certs/keys -while (my($key, $val) = each %$cert_dn) { +for my $key (keys %$cert_dn) { next unless $key =~ /^server/; + my $val = $cert_dn->{$key}; my $name = join '_', $key, 'dsa'; $cert_dn->{$name} = { %$val }; #copy $cert_dn->{$name}->{OU} =~ s/rsa/dsa/;
+1 I suggest: --- /ntfhome/local/lib/perl5/site_perl/5.20.0/x86_64-linux-thread-multi-ld/Apache/TestSSLCA.pm.orig2014-06-23 14:49:44.712628000 -0700 +++ /ntfhome/local/lib/perl5/site_perl/5.20.0/x86_64-linux-thread-multi-ld/Apache/TestSSLCA.pm 2014-06-23 14:51:24.685043000 -0700 @@ -100,10 +100,10 @@ }; #generate DSA versions of the server certs/keys -while (my($key, $val) = each %$cert_dn) { +for my $key (keys %$cert_dn) { next unless $key =~ /^server/; my $name = join '_', $key, 'dsa'; - $cert_dn->{$name} = { %$val }; #copy + $cert_dn->{$name} = { %{$cert_dn->{$key}} }; #copy $cert_dn->{$name}->{OU} =~ s/rsa/dsa/; }
Thanks for the patches guys, but this was already fixed in Apache-Test's trunk by r1544955.