Do not pass `-f' when removing temporary directory: it is not needed,
and rm(1) command call looks safer without it.
This commit is contained in:
parent
492076a332
commit
77b58a80ca
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=439352
1 changed files with 3 additions and 3 deletions
|
@ -16,7 +16,7 @@
|
|||
+# Copy .o files to a temporary location before DTrace messes with them
|
||||
+chomp(my $tmpdir = `mktemp -d -t $$`);
|
||||
+if (system("tar cf - @O_FILES | tar xf - -C $tmpdir") != 0) {
|
||||
+ system("rm -rf $tmpdir");
|
||||
+ system("rm -r $tmpdir");
|
||||
+ exit(1);
|
||||
+}
|
||||
+
|
||||
|
@ -38,7 +38,7 @@
|
|||
|
||||
print "$HDR: Creating instrumented DTrace object: @args";
|
||||
if (system(@args) != 0) {
|
||||
+ system("rm -rf $tmpdir");
|
||||
+ system("rm -r $tmpdir");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
|
@ -47,5 +47,5 @@
|
|||
print "$HDR: Linking with instrumented DTrace object: @ARGV";
|
||||
-exit(system(@ARGV));
|
||||
+my $rc = system(@ARGV);
|
||||
+system("rm -rf $tmpdir");
|
||||
+system("rm -r $tmpdir");
|
||||
+exit($rc);
|
||||
|
|
Loading…
Reference in a new issue