mirror of
https://github.com/curl/curl.git
synced 2026-04-14 18:11:40 +03:00
perl: harden external command invocations
In `adddocsref.pl`, `checksrc-all.pl`, `singleuse.pl` and tests 307, 1013, 1022, 1275, 1707, 1708, 1710. Closes #21097
This commit is contained in:
parent
a56ab9dbc8
commit
20914e3753
11 changed files with 24 additions and 23 deletions
|
|
@ -28,6 +28,8 @@
|
|||
use strict;
|
||||
use warnings;
|
||||
|
||||
use File::Copy;
|
||||
|
||||
my $docroot="https://curl.se/libcurl/c";
|
||||
|
||||
for my $f (@ARGV) {
|
||||
|
|
@ -56,6 +58,6 @@ for my $f (@ARGV) {
|
|||
close(F);
|
||||
close(NEW);
|
||||
|
||||
system("mv $f $f.org");
|
||||
system("mv $f.new $f");
|
||||
move($f, "$f.org");
|
||||
move("$f.new", $f);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue