Skip to content

Commit

Permalink
set license to NOASSERTION if one of combined licenses is NOASSERTION
Browse files Browse the repository at this point in the history
  • Loading branch information
cschneemann committed May 10, 2024
1 parent a41f48b commit 3ada593
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion generate_sbom
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,11 @@ sub parse_debian_copyright_file {
$ret{'copyright'} = join('\n ', sort @copyright_uniq);
%seen = ();
my @license_uniq = grep { !$seen{$_} ++ } @license;
$ret{'license'} = join(' AND ', sort @license_uniq);
if ( grep { $_=~ "NOASSERTION" } @license_uniq ) {
$ret{'license'} = "NOASSERTION";
} else {
$ret{'license'} = join(' AND ', sort @license_uniq);
}
} else {
%ret = undef;
}
Expand Down

0 comments on commit 3ada593

Please sign in to comment.