From cdb39a078899bc8a3fb3ca77f8b689e4c9cac702 Mon Sep 17 00:00:00 2001 From: Joey Vagedes Date: Tue, 30 Jan 2024 14:33:24 -0800 Subject: [PATCH] Update --- .../database/tables/instanced_inf_table.py | 21 ++++++++++--------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/edk2toollib/database/tables/instanced_inf_table.py b/edk2toollib/database/tables/instanced_inf_table.py index 52da78a78..ffce63e3a 100644 --- a/edk2toollib/database/tables/instanced_inf_table.py +++ b/edk2toollib/database/tables/instanced_inf_table.py @@ -222,17 +222,18 @@ def _parse_inf_recursively( library_class_list.append(lib) # - # 2. Append all NULL library instances + # 2. Append all NULL library instances if parsing the component. # - for null_lib in override_dict["NULL"]: - library_instance_list.append(null_lib) - library_class_list.append("NULL") - - for null_lib in self._get_null_lib_instances(scope, library_dict): - if null_lib == inf: - continue - library_instance_list.append(null_lib) - library_class_list.append("NULL") + if inf == component: + for null_lib in override_dict["NULL"]: + library_instance_list.append(null_lib) + library_class_list.append("NULL") + + for null_lib in self._get_null_lib_instances(scope, library_dict): + if null_lib == inf: + continue + library_instance_list.append(null_lib) + library_class_list.append("NULL") # # 3. Recursively parse used libraries