From 54e00569d88a42b2fb40d6892f1876ecfd426767 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Tue, 9 Nov 2021 16:07:30 +0000 Subject: [PATCH] Don't fetch the root sheet's UUID out of the sheet instances. 1) we're storing it now anyway 2) the root sheet UUID is the one UUID that's *not* in the instance array, and previously we were erroneously grabbing the first sub-sheet's UUID (producing duplicate UUIDs). --- eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp b/eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp index b80de580ff..222f450413 100644 --- a/eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp +++ b/eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp @@ -1928,17 +1928,6 @@ void SCH_SEXPR_PARSER::parseSchSheetInstances( SCH_SHEET* aRootSheet, SCH_SCREEN Expecting( "path" ); } } - - // We don't store the root sheet's KIID, so pick it up from any sheet instance paths so - // that it doesn't change on every round-trip. - for( const SCH_SHEET_INSTANCE& instance : aScreen->m_sheetInstances ) - { - if( instance.m_Path.size() > 0 ) - { - const_cast( aRootSheet->m_Uuid ) = instance.m_Path[0]; - break; - } - } }