fixed a potential issue which would be raised by empty value in tools_def.txt file
authorjwang36 <jwang36@6f19259b-4bc3-4df7-8a09-765794883524>
Sat, 8 Jul 2006 11:04:34 +0000 (11:04 +0000)
committerjwang36 <jwang36@6f19259b-4bc3-4df7-8a09-765794883524>
Sat, 8 Jul 2006 11:04:34 +0000 (11:04 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@835 6f19259b-4bc3-4df7-8a09-765794883524

Tools/Source/GenBuild/org/tianocore/build/global/GlobalData.java

index 75c637ffe1dea8f74edf1fb1dddf33c16e358674..bfeea8ae166eb0d290461da6ced829a1cda96b52 100644 (file)
@@ -693,7 +693,8 @@ public class GlobalData {
         String[] commands = getToolChainInfo().getCommands();\r
 \r
         for (int i = 0; i < commands.length; ++i) {\r
-            if (toolsDef.getConfig().get(new String[] {target, toolchain, arch, commands[i], ToolChainAttribute.NAME.toString()}) != null) {\r
+            String cmdName = toolsDef.getConfig().get(new String[] {target, toolchain, arch, commands[i], ToolChainAttribute.NAME.toString()});\r
+            if (cmdName != null && cmdName.length() != 0) {\r
                 return true;\r
             }\r
         }\r