projects
/
p5sagit/p5-mst-13.2.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
(parent:
3068023
)
Protection against overwriting defsubs.h via a symlink
Rafael Garcia-Suarez [Mon, 23 Oct 2006 08:28:08 +0000 (08:28 +0000)]
(by Jim Cromie)
p4raw-id: //depot/perl@29089
ext/B/defsubs_h.PL
patch
|
blob
|
blame
|
history
diff --git
a/ext/B/defsubs_h.PL
b/ext/B/defsubs_h.PL
index
f8c4225
..
0a1f781
100644
(file)
--- a/
ext/B/defsubs_h.PL
+++ b/
ext/B/defsubs_h.PL
@@
-4,6
+4,7
@@
#!perl
my ($out) = __FILE__ =~ /(^.*)\.PL/i;
$out =~ s/_h$/.h/;
+unlink $out if -l $out;
open(OUT,">$out") || die "Cannot open $file:$!";
print "Extracting $out...\n";
print OUT <<"END";