]> git.proxmox.com Git - mirror_edk2.git/commitdiff
1. Fix bug EDKT241 "If and MSA file is missing, the Wizard gives a NULL Pointer Excep...
authorhche10x <hche10x@6f19259b-4bc3-4df7-8a09-765794883524>
Tue, 5 Sep 2006 02:12:02 +0000 (02:12 +0000)
committerhche10x <hche10x@6f19259b-4bc3-4df7-8a09-765794883524>
Tue, 5 Sep 2006 02:12:02 +0000 (02:12 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@1444 6f19259b-4bc3-4df7-8a09-765794883524

Tools/Source/FrameworkWizard/src/org/tianocore/frameworkwizard/common/GlobalData.java
Tools/Source/FrameworkWizard/src/org/tianocore/frameworkwizard/workspace/WorkspaceTools.java

index 4c179929a592be616e4d91faa4f26d0a74a33544..a50d2f104ffcf5e317b27d835fdf634ef1399889 100644 (file)
@@ -93,10 +93,13 @@ public class GlobalData {
 \r
                     } catch (IOException e) {\r
                         Log.err("Open Module Surface Area " + modulePath, e.getMessage());\r
+                        continue;\r
                     } catch (XmlException e) {\r
                         Log.err("Open Module Surface Area " + modulePath, e.getMessage());\r
+                        continue;\r
                     } catch (Exception e) {\r
                         Log.err("Open Module Surface Area " + modulePath, "Invalid file type");\r
+                        continue;\r
                     }\r
                     id = Tools.getId(modulePath, msa);\r
                     mid = new ModuleIdentification(id, vPackageList.elementAt(indexI));\r
@@ -122,10 +125,13 @@ public class GlobalData {
                     spd = OpenFile.openSpdFile(path);\r
                 } catch (IOException e) {\r
                     Log.err("Open Package Surface Area " + path, e.getMessage());\r
+                    continue;\r
                 } catch (XmlException e) {\r
                     Log.err("Open Package Surface Area " + path, e.getMessage());\r
+                    continue;\r
                 } catch (Exception e) {\r
                     Log.err("Open Package Surface Area " + path, "Invalid file type");\r
+                    continue;\r
                 }\r
                 id = Tools.getId(path, spd);\r
                 vPackageList.addElement(id);\r
@@ -150,10 +156,13 @@ public class GlobalData {
                     fpd = OpenFile.openFpdFile(path);\r
                 } catch (IOException e) {\r
                     Log.err("Open Platform Surface Area " + path, e.getMessage());\r
+                    continue;\r
                 } catch (XmlException e) {\r
                     Log.err("Open Platform Surface Area " + path, e.getMessage());\r
+                    continue;\r
                 } catch (Exception e) {\r
                     Log.err("Open Platform Surface Area " + path, "Invalid file type");\r
+                    continue;\r
                 }\r
                 id = Tools.getId(path, fpd);\r
                 vPlatformList.addElement(new PlatformIdentification(id));\r
index 9c8368b0d7c45b0a06fc529e6cc073a670bbbe6a..10b8aee17faeafd756775adcbc23246a9be2c438 100644 (file)
@@ -294,8 +294,9 @@ public class WorkspaceTools {
         for (int index = 0; index < modulePaths.size(); index++) {\r
             modulePath = modulePaths.get(index);\r
             ModuleIdentification id = GlobalData.openingModuleList.getIdByPath(modulePath);\r
-\r
-            v.addElement(id);\r
+            if (id != null) {\r
+                v.addElement(id);    \r
+            }\r
         }\r
         Sort.sortModules(v, DataType.SORT_TYPE_ASCENDING);\r
         return v;\r