You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@velocity.apache.org by nb...@apache.org on 2010/01/04 17:29:24 UTC

svn commit: r895683 - /velocity/engine/branches/1.6.x/src/java/org/apache/velocity/runtime/RuntimeInstance.java

Author: nbubna
Date: Mon Jan  4 16:29:21 2010
New Revision: 895683

URL: http://svn.apache.org/viewvc?rev=895683&view=rev
Log:
VELOCITY-750 fix RuntimeInstance lazy-init() double-checked locking under Java 1.5+

Modified:
    velocity/engine/branches/1.6.x/src/java/org/apache/velocity/runtime/RuntimeInstance.java

Modified: velocity/engine/branches/1.6.x/src/java/org/apache/velocity/runtime/RuntimeInstance.java
URL: http://svn.apache.org/viewvc/velocity/engine/branches/1.6.x/src/java/org/apache/velocity/runtime/RuntimeInstance.java?rev=895683&r1=895682&r2=895683&view=diff
==============================================================================
--- velocity/engine/branches/1.6.x/src/java/org/apache/velocity/runtime/RuntimeInstance.java (original)
+++ velocity/engine/branches/1.6.x/src/java/org/apache/velocity/runtime/RuntimeInstance.java Mon Jan  4 16:29:21 2010
@@ -141,7 +141,7 @@
     /**
      * Indicate whether the Runtime has been fully initialized.
      */
-    private boolean initialized = false;
+    private volatile boolean initialized = false;
 
     /**
      * These are the properties that are laid down over top