This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
If patching fails, bisect-runner.pl should report the name of the file.
authorNicholas Clark <nick@ccl4.org>
Mon, 3 Oct 2011 09:39:58 +0000 (11:39 +0200)
committerNicholas Clark <nick@ccl4.org>
Mon, 3 Oct 2011 09:39:58 +0000 (11:39 +0200)
When commit 0142f0ceeb8dc10a refactored the relevant code into apply_patch(),
it left "perl.c" hard coded into an error message.

Porting/bisect-runner.pl

index 56e023e..20b1f48 100755 (executable)
@@ -116,9 +116,10 @@ sub report_and_exit {
 sub apply_patch {
     my $patch = shift;
 
+    my ($file) = $patch =~ qr!^diff.*a/(\S+) b/\1!;
     open my $fh, '|-', 'patch' or die "Can't run patch: $!";
     print $fh $patch;
-    close $fh or die "Can't patch perl.c: $?, $!";
+    close $fh or die "Can't patch $file: $?, $!";
 }
 
 # Not going to assume that system perl is yet new enough to have autodie