commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From simonetrip...@apache.org
Subject svn commit: r1295951 - /commons/proper/chain/trunk/configuration/src/main/java/org/apache/commons/chain2/config/ConfigParser.java
Date Thu, 01 Mar 2012 22:28:43 GMT
Author: simonetripodi
Date: Thu Mar  1 22:28:43 2012
New Revision: 1295951

URL: http://svn.apache.org/viewvc?rev=1295951&view=rev
Log:
that lazy loading initialization is not thread safe

Modified:
    commons/proper/chain/trunk/configuration/src/main/java/org/apache/commons/chain2/config/ConfigParser.java

Modified: commons/proper/chain/trunk/configuration/src/main/java/org/apache/commons/chain2/config/ConfigParser.java
URL: http://svn.apache.org/viewvc/commons/proper/chain/trunk/configuration/src/main/java/org/apache/commons/chain2/config/ConfigParser.java?rev=1295951&r1=1295950&r2=1295951&view=diff
==============================================================================
--- commons/proper/chain/trunk/configuration/src/main/java/org/apache/commons/chain2/config/ConfigParser.java
(original)
+++ commons/proper/chain/trunk/configuration/src/main/java/org/apache/commons/chain2/config/ConfigParser.java
Thu Mar  1 22:28:43 2012
@@ -47,7 +47,7 @@ public class ConfigParser {
      * <p>The <code>RuleSet</code> to be used for configuring our Digester
      * parsing rules.</p>
      */
-    private RuleSet ruleSet = null;
+    private RuleSet ruleSet = new ConfigRuleSet();
 
 
     /**
@@ -84,9 +84,6 @@ public class ConfigParser {
      */
     public RuleSet getRuleSet() {
 
-        if (ruleSet == null) {
-            ruleSet = new ConfigRuleSet();
-        }
         return (ruleSet);
 
     }



Mime
View raw message