lib: sbom30: Fix agent reference

When a agent reference was being used, the code was not using the
correct base variable to look up the agent

(From OE-Core rev: f3f13f48e214b25cf302b8ce397b630f5aa283fa)

Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Joshua Watt
2024-12-03 15:37:07 -07:00
committed by Richard Purdie
parent 813d6b296c
commit ddbbc9e53c

View File

@@ -393,7 +393,7 @@ class ObjectSet(oe.spdx30.SHACLObjectSet):
if ref_varname:
if ref_varname == varname:
bb.fatal(f"{varname} cannot reference itself")
return new_agent(varname, creation_info=creation_info)
return self.new_agent(ref_varname, creation_info=creation_info)
import_key = self.d.getVar(f"{varname}_import")
if import_key: