Skip to content

Commit

Permalink
scripts/get_abi: fix source path leak
Browse files Browse the repository at this point in the history
The code currently leaks the absolute path of the ABI files into the
rendered documentation.

There exists code to prevent this, but it is not effective when an
absolute path is passed, which it is when $srctree is used.

I consider this to be a minimal, stop-gap fix; a better fix would strip
off the actual prefix instead of hacking it off with a regex.

Link: https://mastodon.social/@vegard/111677490643495163
Cc: Jani Nikula <jani.nikula@intel.com>
Cc: stable@vger.kernel.org
Signed-off-by: Vegard Nossum <vegard.nossum@oracle.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Link: https://lore.kernel.org/r/20231231235959.3342928-1-vegard.nossum@oracle.com
  • Loading branch information
Vegard Nossum authored and Jonathan Corbet committed Jan 3, 2024
1 parent e49ad85 commit 5889d6e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/get_abi.pl
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ sub parse_abi {
$name =~ s,.*/,,;

my $fn = $file;
$fn =~ s,Documentation/ABI/,,;
$fn =~ s,.*Documentation/ABI/,,;

my $nametag = "File $fn";
$data{$nametag}->{what} = "File $name";
Expand Down

0 comments on commit 5889d6e

Please sign in to comment.