Revert "Fix NPE"

This reverts commit 49fee9146f9095f8bb5098de4f742508ca5a13d0.


Project: http://git-wip-us.apache.org/repos/asf/flex-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-falcon/commit/185c3776
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/185c3776
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/185c3776

Branch: refs/heads/develop
Commit: 185c3776c4eab430c5ad11fa681d5403d35f1fbc
Parents: 49fee91
Author: Erik de Bruin <e...@ixsoftware.nl>
Authored: Wed Jul 1 17:34:46 2015 +0200
Committer: Erik de Bruin <e...@ixsoftware.nl>
Committed: Wed Jul 1 17:34:46 2015 +0200

----------------------------------------------------------------------
 flex-compiler-oem/src/flex2/tools/Tool.java | 20 ++++++++------------
 1 file changed, 8 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/185c3776/flex-compiler-oem/src/flex2/tools/Tool.java
----------------------------------------------------------------------
diff --git a/flex-compiler-oem/src/flex2/tools/Tool.java 
b/flex-compiler-oem/src/flex2/tools/Tool.java
index 73d8b4f..132ea31 100644
--- a/flex-compiler-oem/src/flex2/tools/Tool.java
+++ b/flex-compiler-oem/src/flex2/tools/Tool.java
@@ -190,18 +190,14 @@ public class Tool
             throws org.apache.flex.compiler.exceptions.ConfigurationException
     {
         final String configFilePath = ArgumentUtil.getValue(args, 
"-load-config");
-        if (configFilePath != null)
-        {
-            final File configFile = new File(configFilePath);
-            final FileSpecification fileSpecification = new 
FileSpecification(configFile.getAbsolutePath());
-            final ConfigurationBuffer cfgbuf = 
createConfigurationBuffer(Configuration.class);
-            
-            FileConfigurator.load(cfgbuf, fileSpecification, new 
File(configFile.getPath()).getParent(), "flex-config",
-                                  false);
-            
-            return cfgbuf;
-        }
-        return null;
+        final File configFile = new File(configFilePath);
+        final FileSpecification fileSpecification = new 
FileSpecification(configFile.getAbsolutePath());
+        final ConfigurationBuffer cfgbuf = 
createConfigurationBuffer(Configuration.class);
+
+        FileConfigurator.load(cfgbuf, fileSpecification, new 
File(configFile.getPath()).getParent(), "flex-config",
+                false);
+
+        return cfgbuf;
     }
 
     private static ConfigurationBuffer createConfigurationBuffer(Class<? 
extends Configuration> configurationClass)

Reply via email to