summaryrefslogtreecommitdiff
path: root/java/awt
diff options
context:
space:
mode:
authorRoman Kennke <roman@kennke.org>2006-10-10 15:37:57 +0000
committerRoman Kennke <roman@kennke.org>2006-10-10 15:37:57 +0000
commit24714fd922d2c11fc9e86dc78b07d48108ad57f4 (patch)
treec5dd2478784d28932dee74df2da3af5c528f8131 /java/awt
parentcda3426957a570911ff6c2225afbbc213e525271 (diff)
downloadclasspath-24714fd922d2c11fc9e86dc78b07d48108ad57f4.tar.gz
2006-10-10 Roman Kennke <kennke@aicas.com>
* java/awt/Toolkit.java (getDefaultTookit): Make method synchronized to avoid accidentally creating more than one toolkits from different threads.
Diffstat (limited to 'java/awt')
-rw-r--r--java/awt/Toolkit.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/java/awt/Toolkit.java b/java/awt/Toolkit.java
index 08c0cc67f..1f5ccc279 100644
--- a/java/awt/Toolkit.java
+++ b/java/awt/Toolkit.java
@@ -547,7 +547,7 @@ public abstract class Toolkit
*
* @throws AWTError If the toolkit cannot be loaded.
*/
- public static Toolkit getDefaultToolkit()
+ public static synchronized Toolkit getDefaultToolkit()
{
if (toolkit != null)
return toolkit;