mirror of
https://gitlab.com/apparmor/apparmor
synced 2025-08-29 13:28:19 +00:00
retain the filename the profile was loaded from and use that when writting it back out
This commit is contained in:
parent
f213706f17
commit
e43a4769be
@ -875,7 +875,11 @@ sub getprofilefilename ($) {
|
|||||||
my $profile = shift;
|
my $profile = shift;
|
||||||
|
|
||||||
my $filename = $profile;
|
my $filename = $profile;
|
||||||
$filename =~ s/\///; # strip leading /
|
if ($filename =~ /^\//) {
|
||||||
|
$filename =~ s/^\///; # strip leading /
|
||||||
|
} else {
|
||||||
|
$filename = "profile_$filename";
|
||||||
|
}
|
||||||
$filename =~ s/\//./g; # convert /'s to .'s
|
$filename =~ s/\//./g; # convert /'s to .'s
|
||||||
|
|
||||||
return "$profiledir/$filename";
|
return "$profiledir/$filename";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user