Index: /FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/handlers/LocalizedMessages.java
===================================================================
--- /FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/handlers/LocalizedMessages.java	(revision 3626)
+++ /FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/handlers/LocalizedMessages.java	(revision 3627)
@@ -24,4 +24,5 @@
 import java.io.InputStream;
 import java.text.MessageFormat;
+import java.util.Collections;
 import java.util.Enumeration;
 import java.util.HashMap;
@@ -58,8 +59,10 @@
 public class LocalizedMessages {
 
-	private static final Map<Locale, LocalizedMessages> prototypes = new HashMap<Locale, LocalizedMessages>();
+	private static final Map<Locale, LocalizedMessages> prototypes = Collections
+			.synchronizedMap(new HashMap<Locale, LocalizedMessages>());
 	private static final String DEFAULT_FILENAME = "default_messages.properties"; //$NON-NLS-1$
 	private static final String LOCAL_PROPERTIES = "fckeditor_messages"; //$NON-NLS-1$
 	private static Properties defaultProperties = new Properties();
+	
 	private Properties properties;
 	private static LocaleResolver localeResolver;
@@ -67,5 +70,4 @@
 	private static final Logger logger = LoggerFactory
 			.getLogger(LocalizedMessages.class);
-	private static final Object LOCK = new Object();
 
 	static {
@@ -114,17 +116,13 @@
 		if (locale == null)
 			locale = NEUTRAL;
-
-		// TODO how to implement a R/W-Lock on prototypes with new init w/o much code?
-		LocalizedMessages lp = prototypes.get(locale);
-		if (lp == null) {
-			synchronized (LOCK) {
-				lp = new LocalizedMessages(locale);
-				prototypes.put(locale, lp);
-			}
-		}
-
+		
+		synchronized (LocalizedMessages.class) {
+			if (!prototypes.containsKey(locale))
+				prototypes.put(locale, new LocalizedMessages(locale));
+		}
+		
 		// for now we don't need any cloning since the values are accessed
 		// read-only
-		return lp;
+		return prototypes.get(locale);
 
 	}
