diff options
Diffstat (limited to 'dynamic-layers/meta-perl/recipes-security/bastille/files/simplify_B_place.patch')
-rw-r--r-- | dynamic-layers/meta-perl/recipes-security/bastille/files/simplify_B_place.patch | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/dynamic-layers/meta-perl/recipes-security/bastille/files/simplify_B_place.patch b/dynamic-layers/meta-perl/recipes-security/bastille/files/simplify_B_place.patch new file mode 100644 index 0000000..307fdca --- /dev/null +++ b/dynamic-layers/meta-perl/recipes-security/bastille/files/simplify_B_place.patch | |||
@@ -0,0 +1,40 @@ | |||
1 | Upstream Status: Inappropriate [No upstream maintenance] | ||
2 | |||
3 | Signed-off-by: Anne Mulhern <mulhern@yoctoproject.org> | ||
4 | |||
5 | --- | ||
6 | |||
7 | Index: Bastille/Bastille/API.pm | ||
8 | =================================================================== | ||
9 | --- Bastille.orig/Bastille/API.pm 2013-08-21 08:59:17.939950001 -0400 | ||
10 | +++ Bastille/Bastille/API.pm 2013-08-21 08:59:30.983950001 -0400 | ||
11 | @@ -1679,24 +1679,22 @@ | ||
12 | |||
13 | use File::Copy; | ||
14 | |||
15 | - my $original_source=$source; | ||
16 | $source = &getGlobal('BDIR', "share") . $source; | ||
17 | - my $original_target=$target; | ||
18 | |||
19 | if ( -e $target and -f $target ) { | ||
20 | - &B_backup_file($original_target); | ||
21 | - &B_log("ACTION","About to copy $original_source to $original_target -- had to backup target\n"); | ||
22 | + &B_backup_file($target); | ||
23 | + &B_log("ACTION","About to copy $source to $target -- had to backup target\n"); | ||
24 | $had_to_backup_target=1; | ||
25 | } | ||
26 | $retval=copy($source,$target); | ||
27 | if ($retval) { | ||
28 | - &B_log("ACTION","placed file $original_source as $original_target\n"); | ||
29 | + &B_log("ACTION","placed file $source as $target\n"); | ||
30 | # | ||
31 | # We want to add a line to the &getGlobal('BFILE', "created-files") so that the | ||
32 | # file we just put at $original_target gets deleted. | ||
33 | - &B_revert_log(&getGlobal('BIN',"rm") . " $original_target\n"); | ||
34 | + &B_revert_log(&getGlobal('BIN',"rm") . " $target\n"); | ||
35 | } else { | ||
36 | - &B_log("ERROR","Failed to place $original_source as $original_target\n"); | ||
37 | + &B_log("ERROR","Failed to place $source as $target\n"); | ||
38 | } | ||
39 | |||
40 | # We add the file to the GLOBAL_SUMS hash if it is not already present | ||